COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Report Studio => Topic started by: _jl_ on 03 Jul 2013 04:11:33 AM

Title: Why the slicer wont work but Data Item's expression does
Post by: _jl_ on 03 Jul 2013 04:11:33 AM
Hi,

Just wondering. I have a prompt page in which I have query to receive years. By default there were years showing up from 2012 to 2016. So I tried to Slice the year data item. Drag the "Year" item to Slicer and set an expression:

periodsToDate([cubeName].[Date].[Date].[Date], #'[cubeName].[Date].[Date].[Year]->:[PC].[@MEMBER].['+timestampMask($current_timestamp,'yyyy')+'0101-'+timestampMask($current_timestamp,'yyyy')+'1231]'#)
-> Didn't have any effect.

Then removed the slicer and set the exact same expression for the "Year" at the properties pane. -> Working fine by now. Gives me only choises for 2012 and 2013. Just wondering why this works and the slicer doesn't??

BR,
jl