Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Not applicable

Create a Master Dimension item from two fields

I need to be able to create a master dimension item from two fields in Qlik Sense. I have the following example data:

Call ID:                         Parent ID:

C1236                           C4568  

C12345                          

C1236                            C9876 

C123                              C9876

I need to be able to count the distinct [Call ID] and distinct [Parent ID] and then have this total be used as dimension. I am having difficulty getting this to work. I am able to get a count of the distinct [Call ID] but the fx is not counting the distinct [Parent ID]. I have been trying to use the following expression in a KPI object:  Count({<[Liaison Type]={'MSL','FSL'},Objective={'Presentations'},[Product: Description]={'XXX'}>} distinct [Call: Call ID]&'-'&[Parent Call]).

Any suggestions or assistance would be appreciated.

Tags (1)
1 Solution

Accepted Solutions

Re: Create a Master Dimension item from two fields

Hi,

It may be because you are using the distinct for combination of Call ID and Parent ID.

Try this.

Count({<[Liaison Type]={'MSL','FSL'},Objective={'Presentations'},[Product: Description]={'XXX'}>} distinct [Call ID])

+

Count({<[Liaison Type]={'MSL','FSL'},Objective={'Presentations'},[Product: Description]={'XXX'}>} distinct [Parent Call])


Regards,

Kaushik Solanki

2 Replies

Re: Create a Master Dimension item from two fields

Hi,

It may be because you are using the distinct for combination of Call ID and Parent ID.

Try this.

Count({<[Liaison Type]={'MSL','FSL'},Objective={'Presentations'},[Product: Description]={'XXX'}>} distinct [Call ID])

+

Count({<[Liaison Type]={'MSL','FSL'},Objective={'Presentations'},[Product: Description]={'XXX'}>} distinct [Parent Call])


Regards,

Kaushik Solanki

Not applicable

Re: Create a Master Dimension item from two fields

Thanks for the response! This has seemed to work. One additional questions I have. I only want to count [Call ID] when there is not a record in the [Parent ID]. Could you assist with what I would need to add to the script to make this work?