COGNOiSe.com - The IBM Cognos Community

IBM Cognos 10 Platform => Cognos 10 BI => Report Studio => Topic started by: karthik.cognos on 11 Feb 2013 01:51:35 PM

Title: help w/ filter in report studio
Post by: karthik.cognos on 11 Feb 2013 01:51:35 PM
Hi,
I'm trying to create a filter in Report Studio with some conditions using a bunch of AND's & OR's, but the query that is being sent to the Teradata database or the query that is being genereated in report is not grouping the conditions the way I need. Could someone shed some light?

Here is the filter that I would like to build:
(I'll use 'C' for each condition that I have in my filter expression):

(C1 AND C2)
OR
(C3 AND C4)
OR
(C5 AND C6)

But when I see the where clause in the query that Cognos is generating, I see this:

(C1
AND C2
OR C3
AND C4
OR C5
AND C6)

Can someone please help?

Thank you in Advance!
Title: Re: help w/ filter in report studio
Post by: pricter on 11 Feb 2013 04:01:11 PM
Have you tried to put the conditions into brakets?
For example
((C1) AND (C2))
OR
((C3) AND (C4))
OR
((C5) AND (C6))
Title: Re: help w/ filter in report studio
Post by: karthik.cognos on 11 Feb 2013 04:33:16 PM
I tried your suggestion, but no luck.
Any other ideas?