Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Please any one help to resolve this issue
provide some sample data.
the assumption is that you are going 3 months after the selected date, is this right ?
count({< Date = {"<=$(=ADDMONTHS(MAX(Date),-3))<=$(=MAX(Date))"}>}Value)
Thanks for reply Ramon
But we would be selecting only month(not the date) and we would like to have 3months data prior to the selected month.
what is your date format ? or I should Rather say what is you Month Format
what if you select Jan ?
the selection of the month should work with the date as long as both fields are related
hi ramon,
we don't have any date format in our data.
If we select jan2015 then we should get october2014, november2014, december2014 and jan2015 data
and if it is feb2015 then the data should be november2014,december2014,jan2015 and feb2015 data.
Regards,
Chinnu
Chinnu,
Is your "Month" field (Jan-2015, Dec-2014, etc) numeric? If so, you can easily use the SetAnalysis sample Ramon has suggested. If not, then you have to convert it (or create a new field) with date(XXXXXX, 'MMM/YYYY') format and use <= and >= options to specify your months range.
Regards,
VK
the best thing to do is to create your month field to a date or integer format since at the moment I am assuming it is string
,one option is to use date#(month,'MMMYYYY') as month in your script once you do that you could use the following code
count({< Month= {"<=$(=ADDMONTHS(MAX(Month),-3))<=$(=MAX(Month))"}>}Value)
iif you have a calendar with month (m) and date field (d)
=Sum({<m=,d={"<=$(=monthend(max(d)))>=$(=date(addmonths(monthstart(max(d)),-3)))"}>}v)