Thought I would share here a little problem I worked through. I was consistently getting an "error writing to database" when posting to a forum on one of my sites. Turned out the error was caused by an emoticon within the post. Perhaps emoticons are not supported as part of the character set in the MySQL database. Just something to consider if you get a similar error.
In the spirit of sharing...
John