Hantzsch condensation of the (azidoethoxy)ketoester (I) with the benzylidene ketoester (II) formed the protected dihydropyridine (III). Selective deprotection of the cyanoethyl ester under basic conditions provided carboxylic acid (IV), which was further converted to amide (V). Then, acid cleavage of the tert-butyl ester gave acid (VI). Coupling with the (aminopropyl)piperidine (VII) furnished the corresponding amide (VIII). Finally, the azido group was reduced to the target amine by means of trimethyl phosphine.