Hello All-
I am new to Cognos ReportNet and am having an issue with creating a tabular model. Essentially, I need to create 2 sub-queries and join the results. In SQL, I would create a query like:
I tried to accomplish this in ReportNet by creating a tabular model (TAB) that contained 2 other tabular models (T1 and T2). I created T1 and T2 to do the appropriate summarization, and put a filter on TAB [T1].KEY_VAL = [T2].KEY_VAL.
This creates a cross-product between the T1 and T2 which I assume will be filtered after the cross-product is created. I think that this process will be very slow, and I am trying to avoid using Tabular SQL to perform this.
Is there a way to make ReportNet perform sub-queries without cross-products?
Thanks!
--Rob
I am new to Cognos ReportNet and am having an issue with creating a tabular model. Essentially, I need to create 2 sub-queries and join the results. In SQL, I would create a query like:
Code:
SELECT
T1.KEY_VAL,
T1.F1,
T2.F2
FROM
(
SELECT
KEY_VAL,
SUM (F1) F1
FROM
X
GROUP BY
KEY_VAL
) T1
INNER JOIN
(
SELECT
KEY_VAL,
AVG (F2) F2
FROM
Y
GROUP BY
KEY_VAL
) T2
ON
T1.KEY_VAL = T2.KEY_VAL
I tried to accomplish this in ReportNet by creating a tabular model (TAB) that contained 2 other tabular models (T1 and T2). I created T1 and T2 to do the appropriate summarization, and put a filter on TAB [T1].KEY_VAL = [T2].KEY_VAL.
This creates a cross-product between the T1 and T2 which I assume will be filtered after the cross-product is created. I think that this process will be very slow, and I am trying to avoid using Tabular SQL to perform this.
Is there a way to make ReportNet perform sub-queries without cross-products?
Thanks!
--Rob