COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: esanray on 10 Apr 2011 10:39:30 PM

Title: yesterday date without time.
Post by: esanray on 10 Apr 2011 10:39:30 PM
how to get yesterday's date without the time in report studio?
Title: Re: yesterday date without time.
Post by: Steve on 10 Apr 2011 10:41:39 PM
Create a Query calculation and insert this:

_add_days(current_date,-1)
Title: Re: yesterday date without time.
Post by: esanray on 10 Apr 2011 11:29:51 PM

Yes I try this last week but the problem is that when I run the report on 7th April  it display the correct  date that is 6th April( Yesterday Date) but when I run the report today this 11 april this report show me the 6th april date.

My requirement is that when I run the report it show the previous day.
Title: Re: yesterday date without time.
Post by: PRIT AMRIT on 10 Apr 2011 11:35:54 PM
Quotewhen I run the report today this 11 april this report show me the 6th april date

Strange though, ensure what current_date is returning first?
Title: Re: yesterday date without time.
Post by: jahnavi on 11 Apr 2011 08:42:03 AM
I think There are two date columns in your query . Maku sure current date will be the first one
Title: Re: yesterday date without time.
Post by: esanray on 12 Apr 2011 02:24:51 AM
no , any other Suggestion or any other process
Title: Re: yesterday date without time.
Post by: CommandoCognos on 13 Apr 2011 07:29:45 AM
Maybe the report is in the Cognos/DB cache. You could prevent that by setting "Use Local Cache" to "No".

hth