Databases and backups

Author: dp | 06 May 2010 | View Comments
Categories: Servers

Yesterday, I managed to delete the primary

Cleaning up bad data in an SQL database

Author: dp | 02 June 2009 | View Comments
Categories: Uncategorized

Recently, I needed to find all of the data in a table that was being used for HTML output, that had non-printable characters. The following SQL statement should do that for you: select id, name from table_name where name not regexp ‘^[a-zA-Z0-9_ ,&;\/<>(²):%*#?$|!+.\"\'-]+$; This code is MySQL specific, but should be applicable anywhere, really.

Recent Comments