I get a 'WordPress database error' at times when I post. I've tried it enough times to see that it is only happening under one repeatable case:
1. the post has a single quote (apostrophe) in it somewhere
* AND *
2. I've added an image to the post via the new WP2.01 upload tool and chosen to link it to another page NOT to either the original image or to nothing.
Here is such a post: http://blog.designpublic.com/2006/02/14/san-francisco-pillow-fight-club/
Note the apostrophe ("San Francisco's") and the use of the image of the woman linked to another page.
And here is the error I get every time:
WordPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 's
UPDATE IGNORE wp_posts SET
post_author = '1',
post_date = '2006-02-14 22:16:26',
post_date_gmt = '2006-02-15 06:16:26',
post_content = '<img align="right" id="image356" alt="San Francisco Pillow Fight Club" src="http://blog.designpublic.com/wp-content/uploads/2006/02/99942493_2eaad5724a.jpg" />And now for something completely different.
So today around 5:00 PM our bookkeeper Suzie gets up to leave with a pillow in one arm, bike helmet in the other. Someone asked where she was headed, and she mentioned that she was doing battle in an hour at San Francisco's Pillow Fight Club.
We discussed it as a team and decided to send a small Design Public army along with her. Matt (creative) and Noel (resident DJ) tagged along with Suzie, armed to the teeth with an array of decorative contemporary design pillows that we had laying around the office . . . you know, returns.
How's 100% down taste, huh? No, this ain't the tooth fairy, just a 20" by 20" block of cold-hard modern designed pain comin' at you. You want some more? There's more where that came from.
Check out photos from the event in our newest Flickr set.',
post_content_filtered = '',
post_title = 'San Francisco Pillow Fight Club!',
post_excerpt = '',
post_status = 'publish',
comment_status = 'open',
ping_status = 'open',
post_password = '',
post_name = 'san-francisco-pillow-fight-club',
to_ping = '',
pinged = '
post_modified = '2006-02-16 11:14:35',
post_modified_gmt = '2006-02-16 19:14:35',
post_parent = '0',
menu_order = '0'
WHERE ID = 353
Note that I've included the source because there's an image in there.
More QA notes:
- the post saves fine if I insert the image via the WP tool as "not linked" and then add the link afterwards.
- it seems to be getting hung up on the apostrophe but only when the image is added to the post with a link via the AP upload tool.
- I'm running MySQL 4.1.14, Firefox 22.214.171.124 on Mac OS X