Is there a lazy way I can quickly replace all instances of a word with an other, purely in MySQL?
UPDATE sports SET matchup = .....
for example replace Manchester United with Man Utd and Wolverhampton Wanderers with Wolves
Is there a lazy way I can quickly replace all instances of a word with an other, purely in MySQL?
UPDATE sports SET matchup = .....
for example replace Manchester United with Man Utd and Wolverhampton Wanderers with Wolves
Try:
UPDATE table SET column = "new_value" WHERE column = "old_value"
Which becomes:
UPDATE sports SET name = "Man Utd" WHERE name = "Manchester United"
Use the REPLACE command:
UPDATE SPORTS
SET matchup = REPLACE(matchup, 'Manchester United', 'Man Utd')