This is a strange one, and I don't have anything to back it up, just one occurrence. I attempted a CONCAT of a few fields,…
Increase the phpMyAdmin timeout
Yeah, this might not follow all the security best practices in the world, and if your database contains highly sensitive information, you should probably close…
To Correct, or Redirect, That is the Question
While the trusty Apache RewriteRule seems to be a "buzz-phrase" in the SEO world these days, there's a catchy acronym that's losing some ground. That…
ColdFusion Data truncated for column at row 1
You may receive this error when attempting to insert an empty string into a numeric database column. This logic should provide a good example on…
MySQL emptying a table
Just a quick MySQL optimization note. Many times we're required to clear a database table and reset the auto increment counter. This is common with…
cfqueryparam in order by, group by, etc
I've seen quite a few posts on this, many come to the same conclusion that using a (possibly length) switch statement is the best way…
MySQL – Query last months data
You can query last months data without involving your scripting language to manipulate dates. Using MySQL's built in date subtraction methods, this is made simple…
SQL Conditional Update – Update only if NULL
When you find yourself needing to update a record column only if the column is currently NULL (where you don't want to overwrite actual data),…
MySQL Bulk Update with ColdFusion
The example below demonstrates the use of the MySQL CASE statement to cleverly construct a bulk update statement. A huge performance boost over performing individual…
MySQL AsText returns BLOB
I've seen many posts regarding this issue, but most point to a bug in MySQL 5.0, resolved in 5.1. This may be true, although I'm…