Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Filters

Status
Not open for further replies.

ARustad1645

Technical User
Mar 24, 2008
19
US
Is there a way to use a filter on just one single data item?
 
Not sure what you want, but:

1. Using a detailfilter will add an expression to the where clause of the generated SQL (which will limit the set returned, "pre-aggregation" )

2. Using a post-aggregate filter will make the Cognos server filter the aggregated set.

So the answer will be no..

Ties Blom

 
Do you have any other suggestions on how I can limit my information? I'm trying to create a financial report and for one data item I need to limit it by two different means. Our accounts are broken down into 4 segments: Account, Sub-Account, Cost Center, and Project. I want the total of all accounts between 59000-59500 if the cost center is 5000-5500. I'm not sure if I need to try to create a separate query? I actually have 4 different data items I need to limit this way but the cost center range is different for each one. Hope this makes sense.
 
You can't filter a data item differently than the rest of your query, but there's nothing stopping you from creating complex multi-data-item filters. Per your example:

( [cost center] between 5000 and 5500
and [account] between 59000 and 59500)
or
([cost center] not between 5000 and 5500)

When you're using OR conditions you just have to make sure to do it in a single filter since multiple filters are connected by AND.
Another possibility would be to put the valid combinations of account and cost center into a table and join to it.
 
One more afterthought...
You said you have 4 combinations like this. It may get a little tough to read the filter; per your "separate query" comment you could do each of the 4 combinations separately with their respective filters and then UNION the results.
In ReportNet this would be a single query on top of multiple tabular sets/models, in C8 I believe it is separate queries and there's some mechanism for "joining" them via a UNION.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top