Forum Discussion
Anonymous
8 years agoNot applicable
Use non-blank values only
I want to calculate the percentage of a column. Normally the formula I would use is this:
Percentage =
DIVIDE('QC Total Table'[Linear KM],
SUM('QC Total Table'[Linear KM]))
However, I want to only calculate the percentage of a column if there is a value (not blank rows) in another column.
QC %GT Complete =
IF('QC Total Table'[QC Artist] <> BLANK(),
DIVIDE('QC Total Table'[Linear KM],
SUM('QC Total Table'[Linear KM])))In the table, it looks correct. Only shows % values for non blank rows, but I am still not getting a correct result out of 100%, it is still including the blank rows somehow.
Thank you for your help
Try this
QC %GT Complete = IF('QC Total Table'[QC Artist] <> BLANK(), DIVIDE('QC Total Table'[Linear KM], Calculate(SUM('QC Total Table'[Linear KM]),Filter('QC Total Table', 'QC Total Table'[QC Artist] <> BLANK()))))
2 Replies
- parry2kSuper User
Try this
QC %GT Complete = IF('QC Total Table'[QC Artist] <> BLANK(), DIVIDE('QC Total Table'[Linear KM], Calculate(SUM('QC Total Table'[Linear KM]),Filter('QC Total Table', 'QC Total Table'[QC Artist] <> BLANK()))))- AnonymousNot applicable
Gah, I knew I was close. Thank you!