I am trying to replace all '-' in my column but I don't know how to combined SET and REPLACE. Please respond with what my SQL query should look like.
I am trying to replace all '-' in my column but I don't know how to combined SET and REPLACE. Please respond with what my SQL query should look like.
You may need to use the UPDATE statement:
UPDATE ldr.client_order
SET waybill = REPLACE(waybill, '-', '')
WHERE INSTR(waybill, '-') > 0
The WHERE clause you can use to update only those entries had the -. If you are avoid the WHERE clause it will update for all the entries.