Category Archives: mysql

How to install mysql driver on Mac OSX

ruby -e “$(curl -fsSkL raw.github.com/mxcl/homebrew/go)” brew install mysql

Posted in Mac OS X, mysql | Comments Off on How to install mysql driver on Mac OSX

Delete duplicates from table

Sometimes you end up with a lot of duplicates in a table and you need to get rid of them quickly. Do this; create table tmp like zipcodes; alter table tmp add unique (zip, city, state); insert into tmp select … Continue reading

Posted in mysql | Comments Off on Delete duplicates from table

How to repair all tables in all databases in MySQL

When your server loses power unexpectedly, or the kernel panics or otherwise terminates unexpectedly, your mysql tables are probably going to be damaged. You might not find out about it for a while. It is a good idea to check … Continue reading

Posted in Linux, mysql | Comments Off on How to repair all tables in all databases in MySQL