문제

I am relatively new to Cognos tools (4months on/off experience).

My problem is that i had 3 pages ( page1, page2 and summary page).

Page 1 and page 2 are list objects with a total calculation of the total Cost. In the query explorer i have added data items to each query for the list with the following expressions: total([SELL_AMOUNT] for report) and total([SUPPLIER_AMOUNT] for report).

Summary page has a List object also and there is a Total column which is meant to add the totals of page 1 and 2 together: [PG1].[SELL_AMOUNT] + [PG2].[SUPPLIER_AMOUNT]

This works fine when both page 1 and 2 are populated, but when the query for, for example, page 1 returns nothing. Then the summary page list is also blank.

I have tried adding "nvl" and "coalesco([PG1].[SELL_AMOUNT], 0) +[PG2].[SUPPLIER_AMOUNT]" but still returns blank, i think i need a check for if missing or something? Can anybody help, ive been stuck all day.

I am using an oracle DB.

Thanks! Jimmy

도움이 되었습니까?

해결책

I would base the summary page off a unioned query. In this query, pull the two measures, each with a coalesce statement. Add a 3rd measure for the calculation and show this on the report.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top