Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Straight table multiple dimensions

Eligibility : A member who is Eligible for a Program

Enrolled: A member who is Enrolled in a Program.

For Eligibility i calculate the Gender Classification based on :

Dimension:

=If(MEM_GENDER='M','Male',IF(MEM_GENDER='F','Female','Unknown'))

Expression

= COUNT(DISTINCT PERSON_KEY)

For Enrolled i calculate the Gender Classification based on :

Dimension:

=If(ELIG_PERS_GENDR_CD='M','Male',IF(ELIG_PERS_GENDR_CD='F','Female','Unknown'))

Expression

= COUNT(DISTINCT ELIG_PERSON_KEY)


How can i bring these two dimensions under a single straight table as i have to calculate the Eligible/Enrolled percentage for

Gender group.There are two dimensions and two expressions which i have to get them under a single chart?

any ideas?

12 Replies
Not applicable
Author

Hi

PFA... Please reload this application and let me know.... hope it will help you

Anonymous
Not applicable
Author

Hi Poornima,

First of All make a inline load as

Load * inline

[

Gender

Male

Female

Unknown

];

Then Create a chart having dimension as Gender and two Expressions as follows:

Eligible>>

if(Gender='Male', COUNT(DISTINCT{ $<MEM_GENDER={'M'}>} PERSON_KEY),

if(Gender='Female',COUNT(DISTINCT{ $<MEM_GENDER={'F'}>} PERSON_KEY),

COUNT(DISTINCT{ $<MEM_GENDER={'*'}-{'M','F'}>} PERSON_KEY))

)

Enrolled>>

if(Gender='Male', COUNT(DISTINCT{ $<ELIG_PERS_GENDR_CD={'M'}>} ELIG_PERSON_KEY),

if(Gender='Female',COUNT(DISTINCT{ $<ELIG_PERS_GENDR_CD={'F'}>} ELIG_PERSON_KEY),

COUNT(DISTINCT{ $<ELIG_PERS_GENDR_CD={'*'}-{'M','F'}>} ELIG_PERSON_KEY)))

)

As I have directly written the expressions here , there may be any syntax error, anyway logic will be same.

Hope it helps you

Regards

Nitin Gupta

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

     Try this Calculated Expression.

=If(MEM_GENDER='M' and  ELIG_PERS_GENDR_CD='M','Male',IF(MEM_GENDER='F' and  ELIG_PERS_GENDR_CD='F','Female'))

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!