Reputation: 159
I have more than 50 000 records in my database, but problem is that contact number is saved with '-' format.
How I can update all records so contact number will be updated without '-'?
Upvotes: 1
Views: 153
Reputation: 6088
You can use REPLACE(COLNAME, find_string, replace_with)
in UPDATE
Statement
UPDATE Table_Name
SET CONTACT_NO_1 = REPLACE(CONTACT_NO_1, '-', '')
Demo
Upvotes: 3