The DB2 CONCAT function will combine two separate expressions to form a single string expression. It can leverage database fields, or explicitly defined strings as one or both expression when concatenating the values together.
The DB2 COALESCE function returns the value of the first non-NULL expression. The COALESCE function takes a comma separated list of arguments which are evaluated in the order in which they are specified and returns the first non-NULL value found.
I was recently asked by a team member how to go about deleting records from a table based on an arbitrary composite key that was determined by the results of separate query that leveraged one or more tables, and I figured I’d post this solution for everyone.