Useful MySQL Scripts

How to add HTML tags to an entire column within a range of ids

  • update [table_name] set [table_column] = concat('[start_tag]', [table_column], '[end_tag]') where id > 0 and id < 10;

Search and Replace

  • update [table_name] set [field_name] = replace([field_name],'[string_to_find]','[string_to_replace]');