find/replace text mysql

update TABLE_NAME set FIELD_NAME = replace(FIELD_NAME, ‘find this string’, ‘replace found string with this string’); from: http://www.mydigitallife.info/2007/04/23/how-to-find-and-replace-text-in-mysql-database-using-sql/

copy mysql tables

mysql> create database db2; ! /usr/local/mysql/bin/mysqldump -u root –password=pass db1 | /usr/local/mysql/bin/mysql -u root –password=pass db2 originally seen on: http://mywheel.net/blog/index.php/2006/01/05/mysql-duplicate-database-quick-tip/

postgres to mysql workflow

postgres to mysql workflow 1. Export database from postgres to plain text sql. You should do this with the pgAdmin III tool by right clicking on the db you want to export and choosing “Backup …” this will take you to the following screen, where you should select options as displayed below (notice the “Plain”…