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

Grouping Date Ranges

Started by cognosehelp01, 06 Feb 2015 11:55:14 AM

Previous topic - Next topic

cognosehelp01

would be be possible to group Date ranges?
I am looking to get 30 day periods after a vehicle comes out of a maintenance check. I am looking to list multiple vehicles that came out of checks at different times.

So I was wondering if I could do something like between [Day out of Check] and _add_days([Day out of Check],30) for [Vehicle]. I have tried syntax like this but it's not working.

I have created a list that will list the 30 days after and mark if it came out of service, so for a vehicle that finished it's check on Dec 31 it would show:
vehicle| Date | OOS
1 | 1/1 |0
1 | 1/2 |0
1 | 1/3 |1
1 | 1/4 |0
.
.
.
1 | 1/30|0

But I can't use a filter since it fixes on only one of the vehicles instead of getting 30 days after each individually ( so if I added another vehicle that check ended 1/5, it would still only fix on 1/1-1/30)

Just wondering if I should be trying to find a way to group date ranges by vehicle or if I should be looking at this differently?

Robl

I can't really follow exactly what you want to show on your report.

Is it a date based report or a vehicle based report?
Are you comparing Days out of Check to todays date or to a fixed date.

Tell me what you want your final report to look like and I (or someone else) should be able to suggest a way of doing it.

It looks like your half way there with the _add_days function, but I can't see what date you're comparing it to.

cognosehelp01

Hey Robl,

Thanks for replying.

I am looking to have a report that, given a date range, pulls every Vehicle that came out of a maintenance check in that period.
So let's say user inputs Apr 1 - Apr 30, and there are three vehicles: 1, 2, 3.

I want to display these three Vehicles on top, as well as when the vehicle went in check and when it came out of check, I have created a list where these are displayed.
So let's say: vehicle 1 went into check Mar 30 and came out Apr 3, vehicle 2 went in check Apr 7 and came out Apr 30, vehicle 3 went in check Apr 9 and came out Apr 20.

The purpose of this report is to check whether a vehicle went out of service at all in the 30 days after it came out of the check (post check period).

So after we display the list with the vehicles and their check periods, I want to display the post check periods for each and whether the vehicles went out of service in this time frame.
So I am looking for: Apr 4 - May 4 for vehicle 1, May 1 - May 31 for vehicle 2, and Apr 21 - May 21 for vehicle 3.
This is also shown in a list, where if the vehicle went out of service (OOS) a 1 is marked otherwise 0.

Currently I have a filter on this second list([Date] between [Day out of Check] and _add_days([Day out of Check],30)), which seems to only grab the earliest date and the latest dates,
So in this case the list would be from Apr 4 - May 31 for all of these. Making the lists really long and full of garbage.