COGNOiSe.com - The IBM Cognos Community

IBM Cognos 8 Platform => COGNOS 8 => Report Studio => Topic started by: KEKeogh on 02 Dec 2010 01:29:49 PM

Title: Code for last day of current year
Post by: KEKeogh on 02 Dec 2010 01:29:49 PM
I have been using "_make_timestamp(extract(year,current_date),1,1)" in formulas and query calculations to have a report start at the 1st day of the year.

Now I need something similar for the last day of the year.

I tried "_make_timestamp(extract(year,current_date),12,31)" but that didn't work.

I'm using 8.3.

Thanks
Title: Re: Code for last day of current year
Post by: blom0344 on 03 Dec 2010 10:01:54 AM

_add_days(_make_timestamp(extract(year,current_date)+1,1,1),-1)