The synthesis of ethyl or methyl 4-substituted or unsubstituted 2-(dimethylamino)-5- pyrimidinecarboxylates 10-20, which is mainly carried out by reaction of ethyl or methyl 2- [(dimethylamino) methylene]-3-oxoalkanoates with 1, 1-dimethylguanidine, is described.