So my table is https://i.stack.imgur.com/kdGp6.jpg. I want to update the name column so that it removes the Telefon mobil part(to look like the first row).
Asked
Active
Viewed 342 times
1 Answers
2
Use REPLACE function, to replace the specific substring with an alternate substring in the name
field:
UPDATE table_name
SET name = REPLACE(name, 'Telefon mobil ', '');

Madhur Bhaiya
- 28,155
- 10
- 49
- 57
-
Only suggestion is that you may want to replace the space after "mobil" as well, so that the text does not have a leading space. IE: `'Telefon mobil '`. – RToyo Sep 07 '18 at 17:33
-
@Rtoyo ya just added that. – Madhur Bhaiya Sep 07 '18 at 17:34