WordPress.org

Ready to get started?Download WordPress

Forums

PostgreSQL for WordPress (PG4WP)
[resolved] Error on wp_insert_post (3 posts)

  1. velocityzen
    Member
    Posted 2 years ago #

    Hello
    My plugin tried to post some stuff and I've got:

    WP_Error Object ( [errors] => Array ( [db_insert_error] => Array ( [0] => Could not insert post into the database ) ) [error_data] => Array ( [db_insert_error] => ERROR: duplicate key value violates unique constraint "mood_posts_pkey" DETAIL: Key ("ID")=(39) already exists. ) )

    I have clean wordpress install with imported old posts (tool > import), and I don't specify any id on insert.
    Postgres 9.1

    http://wordpress.org/extend/plugins/postgresql-for-wordpress/

  2. velocityzen
    Member
    Posted 2 years ago #

    I'm trying to insert data again and post ID in error message is incrementing
    Key ("ID")=(59) already exists.

  3. velocityzen
    Member
    Posted 2 years ago #

    I'm figure out that posts_seq has not updated it value after wp-import. Maybe it's wp-import's bug. I fixed it through pgphpadmin.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic