Delete column if it exists (Power Query)

 2022-07-29    Power Query    0    252

Open the query in the Advanced Editor and add this line to delete a column if it exists:
#"Remove Column ColumnNameToDelete" = try Table.RemoveColumns(#"PreviousStepRef",{"ColumnNameToDelete"}) otherwise #"PreviousStepRef",