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: 
mahendragaur
Creator
Creator

Sum of Pivot table

Hello,

I have pivot table and I want to get the sum of a column which contains values (Zero or null) but there are some values as 0 (number and text both). I tried Isnull() function but it didn't worked and it is not considering text '0' in calculation.

So, how can I convert text to numbers and get the sum of values.

3 Replies
Anil_Babu_Samineni

Can you provide data if possible due to Aggregation functions won't calculate the Strings. If you have Numeric string then it could work. Better practice may be Live data and result data as you required

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
kamielrajaram
Creator III
Creator III

Hi,

In your script use if(fieldname = '0',0, if (fieldname = 'zero', 0, if (isnull(fieldname)=-1,0,fieldname))) as fieldname.

Hope this helps

Kamiel

mahendragaur
Creator
Creator
Author

I want in expression. I think it'll be good if I'll convert text to number and then do the sum.