Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am trying calculate dates 6 months backward in one expression and one month backward in another expression based on selected variables which are month and year.
The below expressions works fine for any selected month and year above from July to December. When i select any months between Jan and June i am not getting any values.
Think the issue is with the year as it is going to year before, i am not sure how to resolve it, any thoughts?
expression 1: MakeDate(($(vYear)),$(vMonth)-6,01)
expression 2: MonthEnd(MakeDate($(vYear),$(vMonth)-1,01))
Regards,
Karthik
Hi Try it.
expression 1: Addmonths(MakeDate(($(vYear)),$(vMonth),01),-6)
expression 2: Addmonths(MonthEnd(MakeDate($(vYear),$(vMonth),01)),-1)
Regards
Hi,
Try like this, if you are using this in Load script $ is required otherwise no need of $.
expression 1: AddMonhs(MakeDate(vYear), vMonth), -6) // No need of
expression 2: MonthEnd(MakeDate(vYear, vMonth), -1)
Hope this helps you.
Regards,
jagan.
Thank You.
Thank you.
Hi Karthik,
Did you got the answer? If you get the answer please close this thread by giving Correct and Helpful answers to the post which helps you in getting the answer.
Regards,
Jagan.
Hi Jagan Garu,
Yes it worked, i am able to mark it as helpful under actions but i cant see any correct answer button?
Regards,
Karthik.