COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: jmills on 20 Jun 2012 06:09:58 PM

Title: Arbitrary Date Calculation
Post by: jmills on 20 Jun 2012 06:09:58 PM
I'm working on a report where the user would like to select a date, either today or future date, and calculate a person's age based on that date. 

The challenge i'm running into is identifying the necessary Data Item to use.  Is there a way to prompt the user on a prompted date, and not necesarily a date from the report package?

??? = ?Prompt date?

Thanks in advance.
Title: Re: Arbitrary Date Calculation
Post by: MFGF on 21 Jun 2012 02:40:14 AM
You don't need a specific filter to generate a prompt - a data item will do. Try defining a data item in your query with the expression ?Prompt date?, then add a date prompt to your report and set it to use the existing parameter ?Prompt date?. Then you can add your calculation for age and display this in your report. This should hopefully give you what you need.

Regards,

MF.
Title: Re: Arbitrary Date Calculation
Post by: jmills on 21 Jun 2012 11:18:24 AM
That works, thanks!!