Hi @ctedesco3307,
Ah! I am sorry! It seems coalesce() solved the null-append problem, unfortunately masked actual error message because of how the expression is being evaluated. The key detail is that actions('Update_a_row_Header')?['error']?['message'] only exists when the action fails. If the action succeeds, that path is empty, and coalesce() falls back to '' (empty string).
We hvae two options to address this:
1. Use the outputs() object instead of actions():
coalesce(outputs('Update_a_row_Header')?['body/error/message'], '')
Note: This digs into the body of the failed action where the error message is actually stored
2. Use result() to capture failures - PA has a result() function that always returns the full run result of an action (including errors).
coalesce(result('Update_a_row_Header')?['error']?['message'], '')
Note: This is more reliable than actions() when you want to log errors.
I would suggest if can add a condtion as a safe guard - that is append only when failed. So the Condition will check if the status is failed or not. We can do this like: @equals(actions('Update_a_row_Header')?['status'], 'Failed')
If it is true - do the append (step-1 or step-2) else skip.
I am sure some clues I tried to give. If these clues help to resolve the issue brought you by here, please don't forget to check the box Does this answer your question? At the same time, I am pretty sure you have liked the response!