Category Archives: Database

New technology to crack down on house-flipping

Just read an article on cracking down house flipping in NZ, it says “New Zealand’s real estate watchdog is ramping up its crackdown on house-flipping by investing in new technology which allows it to track when properties have been quickly re-sold for huge profits.” So what’s the new technology is about? You would have thought… Read More »

Installing Python Mysql Adapter On Mac OSX

First download and install mysql for Mac OSX Install virtualenv, create a virtualenv and activate it Pip install mysql-python, and you will see an error “EnvironmentError: mysql_config not found” Find the mysql_config by running “sudo find / -name ‘mysql_config’” Go to your /path to virtualenv/build/mysql-python Edit site.cfg Uncomment this line “#mysql_config = /usr/local/bin/mysql_config” and change… Read More »

MySQL locate function

So everyone knows sql LIKE to search wildcard matches the criteria. How about in a situation that you need to return all the rows that has value is part of the criteria string. eg. given a full URL http://www.abc.com/bl/abcdefg/, return all the rows with uri_part field that values are part of the URL string.

Read More »

MyISAM vs InnoDB decision matrix

Ever had problem choosing the right MySQL storage engine? Here is a simple matrix for you to make your decision Is your table is going to be inserted, deleted, and updated much much more than it is going to be selected? InnoDB If you need full-text search MyISAM If you prefer/require relational database design InnoDB… Read More »