Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I have an app that has several calendars, and I am trying to create a variable based on a month date from that calendar date. Everything that I can find so far seems to be a variable based on set dates, or other formulas such as Today().
What I'm looking for is essentially just the current OppMonthYear, less one month.
Can this be done?
Not entirely sure what you mean. But may be this:
Temp:
LOAD Date(AddMonths(Max(OppMonthYear), -1)) as NeededOppMonthYear
Resident Opp_Calendar;
SET vNeededOppMonthYear = Peek('NeededOppMonthYear');
DROP Table Temp;
Sunny,
You're on the right track regarding what I'm looking for. However that script seems to return only a text value of Peek('NeededOppMonthYear');
What about this:
Temp:
LOAD Num(AddMonths(Max(OppMonthYear), -1)) as NeededOppMonthYear
Resident Opp_Calendar;
SET vNeededOppMonthYear = Peek('NeededOppMonthYear');
DROP Table Temp;
Hi Dan, try this:
Temp:
LOAD Num(AddMonths(Max(OppMonthYear), -1)) as NeededOppMonthYear
Resident Opp_Calendar;
SET vNeededOppMonthYear = Peek('NeededOppMonthYear' , 0 , Temp);
DROP Table Temp;
I hope that it help you! ifnot just ask us!
Agustin
Same thing. It seems that the Peek is not coming back as a function.
Same thing as before. It seems that in both yours and Sunny's scrip it's not picking up the PEEK as a function.
I think i understand what you are trying to do. But the question is are you going to be using this variable in the script? because if you do, then you cannot use functions in scripts, you would need to change it to a static value. If this is for front end (and will change based on selections) then why don't you create this on the front end itself?