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

Last Four Weeks of Sales

Started by BigOCombe, 08 Apr 2013 08:41:37 AM

Previous topic - Next topic

BigOCombe

Hello Community,

I am really new to Cognos and I am hoping to get some help here.

What I am needing to do is sum the last 4 weeks of sales. So if I run the report today, I want a column that would show the last four weeks of sales.

Thanks!

wyconian

Hi weeks is a little difficult.  There are built in functions that can do this for days or months.  Take a look at _add_days() or _add_months() which you can find in the list of date functions.  They are designed to add days but if you put in anegative figure they will subtract days.

So you could have a filter like _add_days(sales_date,-28) 0r _add_months(sales_date,-1), that should give you sales for the last 28 days (4 weeks) or for the previous month.  You can then just total the sales as normal.

Hope that helps :-)