Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik and ServiceNow Partner to Bring Trusted Enterprise Context into AI-Powered Workflows. Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
tuncfiratvb
Contributor
Contributor

count distinct if

hi,

I have total_balance_ecl, total_balance_ecl_org and COUNTERPARTYID-MUSTERINO columns. I want to count  COUNTERPARTYID-MUSTERINO of which total_balance_ecl not equal to total_balance_ecl column.

=count({<TOTAL_BALANCE_ECL<>{TOTAL_BALANCE_ECL_ORG}>}distinct [COUNTERPARTYID-MUSTERINO])

formula above doesnt work. thanks for any help in advance.

2 Replies
abhijitnalekar
Specialist II
Specialist II

Hi @tuncfiratvb ,

Try below expression

=count({<TOTAL_BALANCE_ECL -= {TOTAL_BALANCE_ECL_ORG}>}distinct [COUNTERPARTYID-MUSTERINO])

Also If possible, please share the sample data or

You can create a flag at the script level and use the same flag in the set analysis.

eg.

you can create the below flag at the script level 

If((TOTAL_BALANCE_ECL-TOTAL_BALANCE_ECL_ORG)-=0,1,0) as Flag

and use the same like below

=count({<Flag={'1'}>}distinct [COUNTERPARTYID-MUSTERINO])

Regards,
Abhijit
keep Qliking...
Help users find answers! Don't forget to mark a solution that worked for you!
Venus1997
Contributor II
Contributor II

=Count( {<COUNTERPARTYID-MUSTERINO = {"=TOTAL_BALANCE_ECL <> TOTAL_BALANCE_ECL_ORG"}>} COUNTERPARTYID-MUSTERINO)

Community Browser