COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: ghostraider on 17 Jun 2008 10:50:30 AM

Title: Substract from Date Prompt
Post by: ghostraider on 17 Jun 2008 10:50:30 AM
Hi All,

I have a report which uses date prompts. The prompts are 'Begin Date' and 'End Date'. Now, in the title of the report i would like to have the 'End Date' prompt value displayed as 'End Date'-1. Ex: Title between 'Begin Date' and 'End Date-1' . Can someone let me know how to do this day subtraction.

Thanks!!
Title: Re: Substract from Date Prompt
Post by: Darek on 17 Jun 2008 10:52:27 AM
Is your date prompt a date range prompt?
Title: Re: Substract from Date Prompt
Post by: ghostraider on 17 Jun 2008 11:12:05 AM
Hi Darek, thanks for your reply. It is just a Date prompt, not a range.
Title: Re: Substract from Date Prompt
Post by: Darek on 17 Jun 2008 11:15:15 AM
In that case you can use a simple dateadd function to add -1 days to your End Date prompt and place t on the report as a report level calculation.