Answer the question
In order to leave comments, you need to log in
Regular expression in mysql on update?
There is a request like this
UPDATE products SET full_description = REPLACE(full_description, REGEXP "<h2.+>", "<h2>");
REGEXP "<h2.+>"
Answer the question
In order to leave comments, you need to log in
mysql 8.0+? then
UPDATE products SET full_description = REGEXP_REPLACE(full_description, "<h2.+>", "<h2>");
REGEXP_REPLACE
UPDATE products SET full_description = REGEXP_REPLACE(full_description, '<h2.+>', '<h2>');
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question