Try … Otherwise: Power Query’s version of Excel’s IFERROR

Thank to my friend Gráinne who showed me this in Power Query:

Try … Otherwise

In native Excel we have the IFERROR function for when we anticipate errors and know what we want to do with them. In this case, we want to add the Shipped and Inventory amounts. But, if someone has put a note in the Inventory column–instead of an error–we want to return the Shipped amount. Pretty easy to do with Try … Otherwise

There’s also a warning: Power Query does not treat 0, null and [blank] as the same things.

For an intro to Get & Transform (Power Query) try my Lynda/LinkedIn course:
https://www.linkedin.com/learning/instructors/oz-du-soleil?trk=insiders_28299411_learning
Website: https://ozdusoleil.com

My book: Guerrilla Data Analysis 2nd Edition

My old blog: http://datascopic.net/blog-2-2