NOVELTY - Preparing linagliptin, comprises (a) preparing 1-((4-methylquinazolin-2-yl)methyl)-3-methyl-7-(2-butyn-1-yl)-8-((5)-3-hydroxypiperidinyl)xanthine (J), (b) mesylating (J) using methane sulfonyl chloride to obtain 1-((4-methylquinazolin-2-yl)methyl)-3-methyl-7-(2-butyn-1-yl)-8-((1S)-3-O-methanesulfonyl piperidinyl)xanthine (K), (c) converting (K) into 1-((4-methylquinazolin-2-yl)methyl)-3-methyl-7-(2-butyn-1-yl)-8-((5)-3-azidopiperidinyl)xanthine (L) with an azide reagent in a solvent with complete inversion in configuration at the chiral center and (d) reducing the azido group in (L).    USE - The process is useful for preparing linagliptin (claimed), which is useful for treating type II diabetes mellitus. No biological data given.    ADVANTAGE - The process prepares chemically and enantiomerically pure linagliptin with high yield in an economical and environmentally friendly manner.    DETAILED DESCRIPTION - Preparing linagliptin, comprises (a) preparing 1-((4-methylquinazolin-2-yl)methyl)-3-methyl-7-(2-butyn-1-yl)-8-((5)-3-hydroxypiperidinyl)xanthine (J) by combining 1-((4-methylquinazolinyl-2-yl)methyl)-3-methyl-7-(2-butyn-1-yl)-8-bromoxanthine (B) and the salt of (S)-3-hydroxypiperidine (-)-4-chlorotartranilate (M) in a solvent in presence of a base, (b) mesylating (J) using methane sulfonyl chloride to obtain 1-((4-methylquinazolin-2-yl)methyl)-3-methyl-7-(2-butyn-1-yl)-8-((1S)-3-O-methanesulfonyl piperidinyl)xanthine (K), (c) converting (K) into 1-((4-methylquinazolin-2-yl)methyl)-3-methyl-7-(2-butyn-1-yl)-8-((5)-3-azidopiperidinyl)xanthine (L) with an azide reagent in a solvent with complete inversion in configuration at the chiral center, and (d) reducing the azido group in (L) to obtain linagliptin and optionally converting it to its salt, hydrated or anhydrous. INDEPENDENT CLAIMS are included for:    (1) a process for preparation of (J) by combining (B) and (M) in the solvent comprising dipolar aprotic solvents including N,N-dimethylformarnide (preferred), dimethyl acetamide, N-methylpyrrolidone, acetonitrile and dimethyl sulfoxide, in the presence of an inorganic base such as sodium carbonate, lithium carbonate or potassium carbonate (preferred);    (2) the compound (K);    (3) a process for the preparation of (K), comprising mesylating (J) in dichloromethane using methane sulfonyl chloride, without inversion at the chiral center at position 3 in (J);    (4) the compound (L); and    (5) a process for preparation of (L), comprising azidinating (K) with sodium azide in the solvent, preferably dimethylacetamide with complete inversion in configuration at the chiral center.