WordPress.org

Ready to get started?Download WordPress

Forums

WordPress database error (2 posts)

  1. peet_dk
    Member
    Posted 8 years ago #

    Hi, I made my WP2 site offline with help from WAMP5:

    PHP 5.1.2
    MySQL 5.0.18
    phpmyadmin 2.7.0-pl2
    (local on my windows xp home)

    And then I whant to upload it to my domain

    I can edit the post I made with WAMP5, and I also can add comments on the posts I made local.

    But when I try to add a post or a page this error come:
    (here I added a post)

    --------------------------------------------
    WordPress database error: [Duplicate entry '0' for key 1]
    INSERT INTO wp_posts (post_author, post_date, post_date_gmt, post_content, post_content_filtered, post_title, post_excerpt, post_status, comment_status, ping_status, post_password, post_name, to_ping, pinged, post_modified, post_modified_gmt, post_parent, menu_order, post_mime_type) VALUES ('1', '2006-01-18 19:06:51', '2006-01-18 18:06:51', 'sdgsdg', '', 'sdgsdg', '', 'publish', 'open', 'open', '', 'sdgsdg', '', '', '2006-01-18 19:06:51', '2006-01-18 18:06:51', '0', '0', '')

    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 '' at line 3]
    SELECT category_id FROM wp_post2cat WHERE post_id =

    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 ' 1)' at line 2]
    INSERT INTO wp_post2cat (post_id, category_id) VALUES (, 1)

    WordPress database error: [Duplicate entry '0' for key 1]
    INSERT INTO wp_postmeta (post_id,meta_key,meta_value) VALUES ('','_pingme','1')

    WordPress database error: [Duplicate entry '0' for key 1]
    INSERT INTO wp_postmeta (post_id,meta_key,meta_value) VALUES ('','_encloseme','1')

    Warning: Cannot modify header information - headers already sent by (output started at /var/www/sites/peet.dk/wp-includes/wp-db.php:102) in /var/www/sites/peet.dk/wp-admin/post.php on line 59
    -------------------------------------------------

    When I made the export of my local database I converted it to MYSQL40 Because the domain's server is running 4.0.24. You can see a phpinfo here: http://www.peet.dk/phpinfo.php

    I also got some problem with åæø after I converted it, but after some work in notepad+search&replace and paste into the WP-online editor I change all the format-errors.

    What do I have to do to fix it?? Really hope you can help me...

  2. peet_dk
    Member
    Posted 8 years ago #

    Hmpf.. I give up :/ Now I also get a error that link to this site: http://codex.wordpress.org/Enable_Sending_Referrers And it dont fix the problem. (it's when I try to change the WP url from http://localhost to http://peet.dk)

    So.. now I install the WP2 and plugin directly on the server. And then make some copy/paste.. :`|

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags