Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
mambi
Contributor III

Listbox selection and concat order

Hello every,

i have a liste box for customersIDs with values :

ID1,

ID2,

ID3

and i have a textbox

Now i want to display in the textbox my selections from customersIDs but with the selection order :

i mean if i select ID2 first then ID1 then ID3 the result in the textbox i should be ID2,ID1,ID3

any idea ?

Tags (1)
8 Replies

Re: Listbox selection and concat order

That's not possible afaik.


talk is cheap, supply exceeds demand
kumarkp412
Contributor II

Re: Listbox selection and concat order

Hi Mambi,

Please, check the attachment.

But in this, i created the button to show the values and clear the values.

hope this may help you.

Thanks

Kumar

mambi
Contributor III

Re: Listbox selection and concat order

not really what i want because each time i must click the button

galax_allu
Valued Contributor

Re: Listbox selection and concat order

Hi

Try like this ? in text box ...

=if(Aggr(Sum(1), customersID)>0,

                       'Selected: $(=Concat(DISTINCT customersID, ', '))',

                         'Others: $(=Concat({<Country=E({$})>} DISTINCT customersID, ', '))')

mambi
Contributor III

Re: Listbox selection and concat order

doesn't work too

galax_allu
Valued Contributor

Re: Listbox selection and concat order

Hi

will  you try this following as expresssion ?

=if(

  GetFieldSelections( customersID)>0,

  'Selected: $(=Concat(DISTINCT customersID, ', '))',

  'Others: $(=Concat({<customersID=E({$})>} DISTINCT customersID, ',

'))'

)

Edited :

MVP
MVP

Re: Listbox selection and concat order

Agreed - Qlikview does not store or care about the order in which selections are made - it only maintains state. It does store the state history (like clicking the go back and go forward buttons) which you can retrieve using special set analysis modifiers, but it would not be easy (and may not be possible at all) to get this into a sort order for a single field.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
mambi
Contributor III

Re: Listbox selection and concat order

Sorry, but i get the same result, i can't have the wondered order based on my selections

Community Browser