Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
teempi
Partner - Creator II
Partner - Creator II

Calculated dimensions in pivot table

Hello,

I have a pivot table with one calculated dimension called 'Table' and one field dimension called 'User'. The table dimension displays a table name if it's available and a table id if no name is defined. The ID and name are both on a same row in the same table. My expression for the calculated dimension is something like this:

IF(isnull(DBLOG.TABLENAME), DBLOG.TABLEID, DBLOG.TABLENAME)


The problem is that if I use a pivot on a table that doesn't have a name, the 'User' field won't show up at all. However if I open one of the pivots that do have a table name associated with them, the data for the first pivot magically appears. Is there a way to make the data visible every time I click a pivot even if I only have one nameless table expanded?

EDIT: I've added a simple example to demonstrate the problem. Try opening table '3' on it's own and nothing happens. Then try opening 'first' and then '3'.

Thanks in advance!

-Teemu

3 Replies
amars
Specialist
Specialist

Hi ,

One reason I found why it is not relation is there is no relation between the formula and your data . so an alternative approach is to make a relation in between . I have made some changes in the doc. See if it helps.

Regard's

Amar

amars
Specialist
Specialist

Hi ,

One reason I found why it is not relation is there is no relation between the formula and your data . so an alternative approach is to make a relation in between . I have made some changes in the doc. See if it helps.

Regard's

Amar

teempi
Partner - Creator II
Partner - Creator II
Author

Hey Amar and thanks for your reply. Your version of the app gave me a new idea. During the load I can check if the tablename is null and if it is, I can just replace it with whatever I want (for example, the tableID). Then I can use the tablename field in the pivot table and get rid of the calculated dimension altogether!

-Teemu