mysql replace matching but not changing
- by alex
I've used mysql's update replace function before, but even though I think I'm following the same syntax, I can't get this to work-it matches the rows, but doesn't replace.
Here's what I'm trying to do:
mysql> update contained_widgets set preference_values = replace(preference_values, '<li><a_href="/enewsletter"><span class="not-tc">eNewsletter</span></a></li>', '<li><a_href="/enewsletter"><span class="not-tc">eNewsletter</span></a></li> <li> <a_href="/projects"><span class="not-tc">Projects</span></a></li>');
Query OK, 0 rows affected (0.00 sec)
Rows matched: 77 Changed: 0 Warnings: 0
I don't see what I'm missing.
Any help is appreciated.
I edited "a " to "a_" because the site thinks I'm posting spam links otherwise.