Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Ruthie09
Contributor III
Contributor III

Add resulting list of addresses to bubble label

I've been searching for this answer for 2 days and am stuck.

I have the Geo map with a Geo bubble layer that is plotting the countries for each incident ticket (based on whatever filter options the user selected).  A country may have only 1 incident or it might have multiple incidents.  What I need is to add the specific Locations and the Issue Type for each resulting country like this (assumes this country had 3 incidents):

Country

Total Incs

Location 1 - Issue Type 1

Location 2 - Issue Type 2

Location 3 - Issue Type 1

etc.

So far, I've only been able to get the first two lines of the expression with no formatting:

=IncCountry & '<br>' & count(IncNumber)

So how do I write the expression so it will add a new line for each location, whether there is 1 location or 10 locations (realistically, there will likely be fewer than 5 but I can't say for sure)?

I have no experience with HTML* nor Qlik variables or set expressions, so please walk me through the fix step by step.

Thanking everyone in advance.

 

* An online tool was able to convert the text above to HTML in case that helps.

<p style='margin:0in;margin-bottom:.0001pt;font-size:15px;font-family:"Calibri",sans-serif;'><strong><span style="font-size: 11px;">Country</span></strong></p>
<p style='margin:0in;margin-bottom:.0001pt;font-size:15px;font-family:"Calibri",sans-serif;'><span style="font-size: 11px;">Total Incs</span></p>
<p style='margin:0in;margin-bottom:.0001pt;font-size:15px;font-family:"Calibri",sans-serif;'><span style="font-size: 11px;"><strong>Location 1 - <span style="color:red;">Issue Type 1</span></strong></span></p>
<p style='margin:0in;margin-bottom:.0001pt;font-size:15px;font-family:"Calibri",sans-serif;'><span style="font-size: 11px;"><strong>Location 2 - <span style="color:#FF9900;">Issue Type 2</span></strong></span></p>
<p style='margin:0in;margin-bottom:.0001pt;font-size:15px;font-family:"Calibri",sans-serif;'><strong><span style="font-size: 11px;">Location 3 - </span><span style="color: red; font-size: 11px;">Issue Type 1</span></strong></p>

Labels (1)
1 Solution

Accepted Solutions
martyginqo
Partner - Creator
Partner - Creator

I wouldn't have time to walk through this, but in the past I think I would have used the concat function to aggregate this string. Start with simple concat (field, ',') and build from that.

Martin.

View solution in original post

5 Replies
Ruthie09
Contributor III
Contributor III
Author

Anyone?

martyginqo
Partner - Creator
Partner - Creator

I wouldn't have time to walk through this, but in the past I think I would have used the concat function to aggregate this string. Start with simple concat (field, ',') and build from that.

Martin.

Steven_Haught
Creator III
Creator III

Would it be possible for you to share a sample of your data? 

Ruthie09
Contributor III
Contributor III
Author

This was the answer.  I didn't realize CONCAT was not the same as using ampersands.  Thank you, Marty.

This is what I ended up with.

=IF(IncP1P2Flag = 'Yes', IncCountry & chr(10) & 'Total Tickets - ' & count(IncNumber) & chr(10) & (CONCAT(Distinct IncLocation & ' - ' & IncLocationType,chr(10))), IncCountry & chr(10) & count(IncNumber))

SalvatoreBaker
Contributor
Contributor

Your information is very interesting. Thank you for sharing.

Tellpizzahut