It has been 7 years since the QlikView for Developer's Cookbook was published!
The book, which was very much targeted at QlikView developers, is still available. Just for fun, I thought that it might be interesting to write a series of posts looking back at some of those recipes and seeing how they could be recreated in Qlik Sense Business.
In this first post, I'll look at the very first recipe - Creating custom pop-up labels on a bar chart.
In QlikView, it was necessary to manually put together a text expression to join multiple values, with their functions to ensure correct formatting, together and ensure values appear on separate rows using line feeds (using the chr function) - something like this:
& 'Sales : ' & Num(Sum(Sales), '$(MoneyFormat)')
& 'Costs : ' & Num(Sum(Costs), '$(MoneyFormat)')
& 'Margin : ' & Num(Sum(Sales)-Sum(Costs), '$(MoneyFormat)')
& 'Margin % : ' & Num(1-(Sum(Costs)/Sum(Sales)), '0.0%')
In Qlik Sense, it is a little easier. 😊
In most of the major chart types there is a sub-property in the Appearance property called Tooltip.
|Hide basic rows||This either shows or hides the default Tooltip values. Useful to turn off if you are doing something custom.|
|Description||An expression that defines a piece of text to present within the tooltip. Could be used to present useful information for users such as how these metrics compare with others.|
|Measures||One or several measures to display. Each measure has typical sub-properties for measures such as label and numeric format.|
|Images||An image to display in the Tooltip - either a static one from the Media libaray, or from a Url (which could be dynamic!)|
So, to recreate the manually constructed text from QlikView, we just need to turn off the Hide basic rows option, leave the Description blank, and add four Measures with appropriate formats. We might end up with a result like this:
As well as holding a Master's Degree in Data Analytics, Stephen Redmond is a practicing Data Professional of over 20 years experience. He is author of Mastering QlikView, QlikView for Developer's Cookbook and QlikView Server and Publisher.