Use TIMESTAMPADD and TIMESTAMPDIFF functions to find different dates.
If you want specific month then use below code in fx of column.
For current - CASE WHEN 1=0 THEN "- Project"."Project Manager" ELSE MONTHNAME(CURRENT_DATE) END
For previous - CASE WHEN 1=0 THEN "- Project"."Project Manager" ELSE MONTHNAME(TIMESTAMPDIFF(SQL_TSI_MONTH,1,CURRENT_DATE)) END
OR
For current month -> monthname(current_date)
For prev month -> MONTHNAME(TIMESTAMPADD( SQL_TSI_DAY , -(1), TIMESTAMPADD( SQL_TSI_DAY , DAYOFMONTH( CURRENT_DATE) * -(1) + 1, CURRENT_DATE)))
Until Next Post...Keep Smiling :)
will the below code wors?
ReplyDelete(TIMESTAMPDIFF(SQL_TSI_MONTH,1,CURRENT_DATE))