If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Date range filter for Cube query

Started by Ricardo Julio "Ricky" Villa, 23 Mar 2016 10:51:57 AM

Previous topic - Next topic

Ricardo Julio "Ricky" Villa

Hi,

I have a Report Studio report populated from a PowerPlay Cube.

The report has a start month prompt and an end month prompt.  Example MUN values the prompts will return are:

start month: [Saxon Sales Performance Cube].[All Dates].[All Dates].[Month]->:[PC].[@MEMBER].[20150101-20150131]
end month: [Saxon Sales Performance Cube].[All Dates].[All Dates].[Month]->:[PC].[@MEMBER].[20160401-20160430]

How do I apply a filter to only return data between these 2 periods (i.e. date range filter).

Cheers,

Ricky

Ricardo Julio "Ricky" Villa

Hi,

Sorry, error in my original post... been a long day :(

The prompts actually just return a month number, e.g. 1, 2, 3,4....12 and there are separate Year prompts.

The MUN's format for month categories are as given in original post, e.g.
[Saxon Sales Performance Cube].[All Dates].[All Dates].[Month]->:[PC].[@MEMBER].[20150101-20150131]

Cheers,

Ricky

Ricardo Julio "Ricky" Villa

Just worked it out (or found it on google)...

intersect(lastPeriods(-9999, parallelPeriod( [Saxon Sales Performance Cube].[All Dates].[All Dates].[Year],1,[Saxon Sales Performance Cube].[All Dates].[All Dates].[Month]->?p1?)),lastPeriods(9999, parallelPeriod([Saxon Sales Performance Cube].[All Dates].[All Dates].[Year],1,[Saxon Sales Performance Cube].[All Dates].[All Dates].[Month]->?p2?)))

Ricardo Julio "Ricky" Villa

Sorry that was for previous year periods :(

this is it:

intersect(lastPeriods(-9999, [Saxon Sales Performance Cube].[All Dates].[All Dates].[Month]->?p1?),
lastPeriods(9999,[Saxon Sales Performance Cube].[All Dates].[All Dates].[Month] ->?p2?))