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

Referencing different queries in the same report

Started by gutterline, 08 Feb 2011 08:16:11 AM

Previous topic - Next topic

gutterline

I have a report that contains 5 queries.  I need to be able to reference one query from another for a reporting total function.

I know there has to be a way to make one query reference another, just to use a field.

I probably haven't described this very well and if more information is needed, I'll be more than happy to elaborate.

Thanks,
Mark

melee

I don't have a solid look on this, but I've been able to filter by other queries by simply including the full path of the data item - for example, [DATAITEM1] in [Query1].[Count Total]

Where DATAITEM1 resides in Query2 or something similar. i haven't tried this as a straight up data item, but I'd assume that as long as you're bringing a total and not creating a join, it should work. I'll test it and get back to you with a definitive.

redmist

what melee is suggesting is like a sub query. I believe you will have to enable outer join for that to work, so make sure Query1 has only 1 record
Also think the syntax has to be [DATAITEM1] in ([Query1].[Count Total])

melee

Yeah, my pseudo code never renders correctly :P