In my level of understanding, if I want to make an amide from an ester, I should add:
- $\ce{H3O+}$ for hydrolysis to make carboxylic acid
- $\ce{SOCl2}$ to form acid chloride
- $\ce{ROH}$, pyridine to form the ester as product
I think this is a good way since it is difficult to form a more reactive product compared to the reactant, but in one of the question, I really want to try to make the 3-step process 1-step:
My attempt is to use a protonated $\ce{ROH}$ as acid-catalst, this time, to form a methyl ester. I used methanol, and somehow I can get to the end.
[for the 4th intermediate, I searched online and found that $\mathrm{p}K_\mathrm{a}$ of $\ce{(CH3)2NH = 10.73}$, $\mathrm{p}K_\mathrm{a}$ of $\ce{CH3OH = 15.56}$, this means that $\ce{(CH3)2NH+}$ is a better leaving group (lower $\mathrm{p}K_\mathrm{a}$ --> lower basicity --> more stable in the reaction mixture)]
Can someone please kindly tell me what is wrong with my mechanism? I know it should be wrong, since the 3-step process is the most suitable way and yield the most.