if `try otherwise` not remembered then read this or else just `IFERROR`
me@jaykilleen.com wrote this over 3 years ago and it was last updated over 3 years ago.
In excel something like IFERROR([price]*[quantity],0)
or `IFERROR([first_name] & " " & [last_name],"") can be written as
I am writing this example in the context of adding a column to a table so you can ignore the part like Table.AddColumn("column_name", each
and just focus on the parts try ... otherwise ...
.
Table.AddColumn("revenue", each try [price] * [quantity] otherwise 0, type number)
or
Table.AddColumn("name", each try [first_name] + " " + [last_name] otherwise "", type text)