Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Save $650 on Qlik Connect, Dec 1 - 7, our lowest price of the year. Register with code CYBERWEEK: Register
cancel
Showing results for 
Search instead for 
Did you mean: 
jason_nicholas
Creator II
Creator II

Using chart column sum in a separate expression

I have a chart showing support minutes per event size. The expression column header also has a total, and I want to provide the percentage of the total related to each entry. I haven't been able to get this to work, and I would appreciate any suggestions from this group.

For example, my data chart looks like this:

Event SizeSupport Minutes
Small1000
Medium3000
Large2000

The Support Minutes header totals 6000. I want to create an additional column that shows 16.6%, 50%, and 33.3% respectively.

Here are the issues I have encountered:

  • I have to add a specific Interval Format (mm) to get the time to calculate and show and calculate minutes properly. However, the Interval format option does not allow the "Show in Percent (%)" option. The format settings which do allow "Show in Percent (%)" format the data incorrectly.

  • The values involved in creating the "minutes" entries require set analysis as well as the results of individual selections

Here's what I have tried:

  • Creating a variable        varSupportTime =  SUM({$<Type={'Webcasts'}>}Duration)    this one results in a value of mm2e+002, so not helpful.
  • I've tried adding the NUM function    NUM(SUM({$<Type={'Webcasts'}>}Duration),'mm') to force the formatting, but this didn't work.
  • The variable, if built correctly, could be used to divide the Support Minutes and generate a percentage.

An additional issue with my variable is that it does not change with additional selections. For example, right now it totals the entire data set. If I want to select a specific month, week, location, etc, I would want the sum to follow.

  What do I need to do to get a percentage column which shows the value in the Support Minutes column divided by the total of that column, while at the same time maintaining the number format (mm)? Thanks in advance.

1 Solution

Accepted Solutions
sunny_talwar

May be try this

Sum({$<Type={'Webcasts'}>}Duration)/Sum(TOTAL {$<Type={'Webcasts'}>}Duration)

View solution in original post

2 Replies
sunny_talwar

May be try this

Sum({$<Type={'Webcasts'}>}Duration)/Sum(TOTAL {$<Type={'Webcasts'}>}Duration)

jason_nicholas
Creator II
Creator II
Author

I knew it had to be easy. That worked perfectly Thank you.