Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I am new to QlikView and I need to find out how to display the data from a table column concatenated in a string.
I am loading the data from 2 text files and my data model looks like this:
I am interested in the RSSFEEDCategory table. The data inside looks like this:
Now take for example the 3 last rows of this table. When I create a Pivot table it displays the data like this:
But I need it to be displayed like this:
Title | category |
---|---|
Bike Q&A | @breaking-news, @hp-top-stories, mount scott, mount tabor, ocyclers, oregonian cycling, rocky butte |
Is it possible to do this in QlikView? I was thinking to put a function in the load similar to a cursor in SQL but I do not know if it is possible. The other options I can think about are an expression or maybe a macro.
Can any of you point me in the right direction?
Thank you.
You can use a table chart with dimension Title and an expression
=concat(category, ', ' )
This will create a concatenated string of your category values, but sorted alphabetically.
If you want it to be displayed in a special order, you can use the third parameter to concat, the sort weight.
For example, if you wan the load order, you can create an additional field in the script
RSSFeedCategory:
LOAD
key,
category,
recno() as categorySortWeight
FROM ...
then use this field:
=concat(category, ', ', categorySortWeight)
You can use a table chart with dimension Title and an expression
=concat(category, ', ' )
This will create a concatenated string of your category values, but sorted alphabetically.
If you want it to be displayed in a special order, you can use the third parameter to concat, the sort weight.
For example, if you wan the load order, you can create an additional field in the script
RSSFeedCategory:
LOAD
key,
category,
recno() as categorySortWeight
FROM ...
then use this field:
=concat(category, ', ', categorySortWeight)
Thank you swuehl. That solved my problem.