Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
How to get the last date of the month in the expression Max({<Year={$(=Max(Year))},Month={$(=Month(Max(TranDate)))}>} TranDate)
where TranDate is in DD/MM/YYYY format and I need the last date of the month also in the same format.
Yeah, but the time fraction of a date returned by monthstart is 0. The time fraction of a date returned by monthend however is 1 millisecond less than a full day. It makes a difference when you want to compare or select the last date in a month with the result from a calculation that should return the last date of a month. MonthEnd won't unless you use the floor function on its result. MonthStart(Date, 1)-1 will give you the last day of the month too.
Got it
Thanks for the explanation
Its always giving date in no. like 42429 for 29/02/2016.
Best Regards
PKP
Use Date() on top this, it will convert to Date format.
Regards,
Jagan.