Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I am using below functions to fetch current year and current month less one month but I am getting data for all years.
Although month is as expected by me.
let vCurrentMonthYear = '=year(addmonths(max(BillDate),1))';
let vPriorMonth = '=month(addmonths(max(BillDate),-1))';
Please help.
Thanks and Regards,
Abhijit Arankalle.
Let vReportFromDate = YearStart(Date(BillDate));
Let vReportDate = Date(AddMonths(Date(BillDate),-1))
then put on the load script..
Where BillDate>= '$(vReportFromDate)' and BillDate<= '$(vReportDate)'
OR
Where BillDate>= YearStart(Date(BillDate)) and BillDate<= Date(AddMonths(Date(BillDate),-1))
Hi Nasir
Thanks for your response but I am still not getting current year.
Regards,
Abhijit
check the date format it wil work or share the sample code
Hi,
Are you trying to solve this in front end or load script?
If it is in front-end then share your current set analysis and someone will help write the expression. Nasir has already set you in the right direction.
Best,
Ali A
Hi
Thanks for your response. Actually, I am trying this in load script and I do not want user to update script every time to fetch current year and current month -1 data from SQL.
Thanks and Regards,
Abhijit Arankalle.