Wednesday, February 4, 2009

More head banging

MySQL will allow you to alter a column name to be a reserved keyword.

ALTER TABLE `pornstar` CHANGE `isforeign` `foreign` bit NULL DEFAULT NULL;

But, as soon as you try to insert a row with that column, you get a totally unhelpful error message.

Why do you make my life so difficult sometimes?

No comments: