Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Support Cases coming to Qlik Community Oct. 4! Start chats, open cases, explore resources: READ DETAILS
Showing results for 
Search instead for 
Did you mean: 
Contributor III
Contributor III

Straight table average using columns excluding zeros

Hi - I have a straight table, with 8 columns.  I'd like to work out the average of these 8 columns but excluding zeros as this will skew the count.

This works well, but gives me skewed average due to the zeros within columns:


Thanks guys.

2 Replies
Creator II
Creator II

Obviously you can use if conditions. But if you need a solution without if condition then use the below expression. This might solve your problem. 



(-1*( (column(1)>0) + (column(2)>0) + (column(3)>0) + (column(4)>0) + (column(5)>0) + (column(6)>0) + (column(7)>0) + (column(8)>0) ))

Support (Former)
Support (Former)

I would believe you are likely going to have to use Set Analysis in that case to accomplish things:


That post may get you on the right track, here is the base Design Blog URL in case you want to search for other related posts there:



To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.