Forum Discussion
TCatron18
Helper II
1 year agoReplace value based on conditions from multiple columns
I'm running into an issue trying to replace a value within a column that looks at a value within the column itself as well as a value within a separate column. I have column named [Sender's Posi...
Bibiano_Geraldo
Super User
1 year agoHi TCatron18,
Apply this code in your query editor. This approach ensures that only null values are replaced based on the specified conditions.
= Table.TransformColumns(
#"Renamed Columns4",
{
{
"Sender's Position Category",
each if [Sender's Sr Business Unit] = "xSystem Generated" and _ = null then "xSystem Generated"
else if _ = null then "N/A"
else _
}
}
)
I hope this helps! 🎯
If you found this answer helpful:
✔️ Mark it as the solution to help others find it faster.
👍 Give it a kudo to show your appreciation!
TCatron18
Helper II
1 year agoBibiano_Geraldo This still seems to be changing all of the null values to N/A. I'm also getting the 'invalid identifier' error when using the square brackets, but even when changing to quotations it's still changing all to N/A.