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

Using dates in Report Studio

Started by phoenixfire, 28 Oct 2010 12:18:22 PM

Previous topic - Next topic

phoenixfire

Hello,
I am trying to run a report based on a two-year date selection. The input date for this selection is actually in the form of a date-timestamp.
This parts works fine. However, I am trying to exclude just one day in this two year period in the prompt.
For eg.
Report runs based on Entry Date from 01Oct08 to 30Sep10. I am trying to exclude 10Sep10 from this date range. Anything that was entered on the 10th needs to be ignored.

Any ideas? Thanks in advance.

cognostechie

Why are you trying to exclude 10 Sep 10 ? Any logic attached to it? If yes, there are various ways. Ex: Create a calculated column with the logic, assign a value to 10 Sep 10 based on the logic, then use that column in the filter with that value.

If no logic, you could just hard code 10 Sep 10 in the filter to exclude it. Hard coding is not the preferred way though.

rockytopmark

2 filters in 1 Detail filter object:

Conceptual example:

[theDate] between 01-Oct-08 and 30-Sep-2010
and
[theDate] <> 10-Oct-10

implement however you need, but this should do the trick for you

phoenixfire

Thanks for both suggestions. But I tried them already. It doesn't work for some reason. The report still includes information from 10sep10.

CognosPaul

You said your field is a timestamp. Does it include the time too?
10/09/2010 12:00:01 is not the same as 10/09/2010.

Try something like: cast([theDate],date) <> 10-Sep-10
or possibly: to_char([theDate],'yyyymmdd')<>'20100910'