hi ,

try this.

datediff( 'mm', d1, d2 ).where mm is month.for date you give dd.ok