Forum Discussion
Anonymous
6 years agoNot applicable
we cannot replace value null to type text
Looking for a simple solution I am pivoting a table to create a column for each value = Table.Pivot(#"Changed Type", List.Distinct(#"Changed Type"[Status]), "Status", "Count") it is returning some...
danextian
6 years agoSuper User
Hi Anonymous
Did a test and replacing null in a column that is type number with zero works fine. The formula looks like this Table.ReplaceValue(#"PreviousStep",null,0,Replacer.ReplaceValue,{"Number"})
Try converting your number column to type text first, do a replace and convert it back to number after. Alternatively, you may create a custom column with a formula similar to this if [Column] = null then 0 else [Column] and then delete the original column
- Anonymous6 years agoNot applicable
thanks, I tried both of these approached and neither worked.
- danextian6 years agoSuper User
Anonymous , Are you able to attached your pbix with the data source?
- Anonymous6 years agoNot applicable
I don't think I can share the data.
the problem occurs as soon as I pivot
= Table.Pivot(#"Changed Type", List.Distinct(#"Changed Type"[Status]), "Status", "Count")