Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

If more than one type of acct - return 'Multi' else Concat two descriptions

I am using the following to list all results for a specific customer.

Concat(DISTINCT{<as_of_dt_MMM_YYYY=

>}slr_1_desc & ' - ' & slr_2_desc,' , ')

The result looks like:

CI - CI Lending , CRE - Commercial Construction , CRE - Commercial Term
CI - CI Lending                                                                                             

Instead I would like the option to be if there is more than one type of account, then return 'Multi' else slr_1_desc & ' - ' & slr_2_desc,' , '

Any thoughts?

Thank you.

3 Replies
sunny_talwar

Not sure if I completely understand, but may be this:

Alt(Only(DISTINCT{<as_of_dt_MMM_YYYY= >} slr_1_desc & ' - ' & slr_2_desc), 'Multi')

For your given output, the result should change from

CI - CI Lending , CRE - Commercial Construction , CRE - Commercial Term
CI - CI Lending  

to

Multi
CI - CI Lending
swuehl
MVP
MVP

Try something like

=If( Count(DISTINCT slr_1_desc & ' - ' & slr_2_desc) = 1, slr_1_desc & ' - ' & slr_2_desc, 'Multi')

Anonymous
Not applicable
Author

This option worked! 

Thank you for the quick response!