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

Handle multiple properties in one field (one variable)

Hello

I have an excel document that looks like this:

IDVariable1Variable2
1

A

AA, CC, EE
2BBB, CC
3CAA, DD, EE, FF
4DBB, DD

So Variable2 for each record contains multiple properties seperated by a comma.

Now if I load this in Qlikview I want to use Variable2 as a graphs-dimension in a bar-chart, where each property (like 'AA' or 'BB') is a single bar. And also that the for instance ID 1 is represented in the bars for AA, CC, and EE.

how can I achieve this?

Your help would be much appreciated.

Regards,

Peter

1 Solution

Accepted Solutions
tresesco
MVP
MVP

Load Variable2 field using SubField() function, like:

Load ID,

          Variable1,

          SubField(Variable2, ',') as Variable2

From <>;

Subfield() would create one record for each substring separated by comma (here).

View solution in original post

2 Replies
tresesco
MVP
MVP

Load Variable2 field using SubField() function, like:

Load ID,

          Variable1,

          SubField(Variable2, ',') as Variable2

From <>;

Subfield() would create one record for each substring separated by comma (here).

pepe2209
Creator
Creator
Author

Thanks for your comment.

This does achieve what I need, but it also multiplies the number of records and I don't want that to happen...

is it possible to do this without multiplying records?

edit-

Oh wait offcourse, by loading ID (as key variable) and subfield(Variable2, ', ') as a second table it works.

Thanks!