
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
AddMonths in set analysis?
Hi,
Is it possible to use Addmonths in set analysis?
I want to rewrite this:
sum
({$ <BETBOKFD_IN = {">2008-06-30"}> }_ForsCounter)
With something like this:
sum
({$ <BETBOKFD_IN = {">=$(AddMonths(AVSERPERIOD,-15)"}> }_ForsCounter)
Is it possible and how do I write it (as the above code dosen't work)?
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Christina,
it´s working now. You missed brackets in your expression and please avoid spaces.
Have a nice weekend!
Rainer

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
see the attached example.
God luck!
Rainer

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks,
Now I can copy your syntax, I still doesn't work for me though. I'll have another try at it later.
I'll let you know.
Regards,
Christina

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Christina,
be aware of the date format. That´s number one of most of the problems by using "Set Analysis".
Rainer

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi again,
I've tried Rainer's soloution, but apparently I'm doing something wrong as his set analysis is working.
Therefore I attached my example.
All suggestions are welcome.
By the way my version is 8.5
Regards,
Christina

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Try this.....
sum
({<BETBOKF_IN = {"<=$(=date(max(addmonths(AVSERPERIOD,-15))))>=$(=date(max(addmonths(AVSERPERIOD,0)))))"}>} _ForsCounter)Cheers.
Ad.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Tnks Abu, but it still doesn't work, pls se the attached file with the code. It's a very stripped bit of code just to show the problem.
To add the date is always a good idea though.
Christina

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Christina,
it´s working now. You missed brackets in your expression and please avoid spaces.
Have a nice weekend!
Rainer

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks very much Rainer,
I really appreciate you taking the time to correct my misstakes.
I found set analysis very useful, but a bit hard to get right.
I also wish you a nice weekend.
Christina
