Recent Posts

Archive

2012

2011

2010

2009

2008

2007

2006

Tags

Authors

Brad Montgomery

Feeds

RSS / Atom

Blog

Viewing posts tagged mysql

Data Truncated Errors

May 5th, 2009 In: None By: Brad Montgomery 5 comments

I recently ran into some of the Data truncated for column ... errors in my django apps. After a little digging, I've discovered that my particular problem lie in the structure of the underlying MySQL tables. Particularly with varchar columns.

read more

How to Set up a Foreign Key Constraint in MySQL

April 4st, 2009 In: None By: Brad Montgomery 11 comments

The default storage engine in MySQL (MyISAM) does not support Foreign Key constraints. If you want to use Foreign Keys in Mysql, you need to use InnoDB.

read more

Migrating PHP scripts to MySQL from PostgreSQL

Jan. 1th, 2007 In: None By: Brad Montgomery 2 comments

I've recently had to work on a project where I needed toconvert some very basic PHP code thataccessed a postgresqldatabase so that it would work with mysql. For the most part, this has beenfairly simple thanks to rpl. Many of PHP'sdatabase functions have very similar names, so I simply use rpl toconvert the existing code. Here's a simple bashscript that I put together to convert some of my postgresqlfunctions to mysql:

read more

Page 1 of 1:

  • 1