• Resolved solarblitz77

    (@solarblitz77)


    We have just tried to add a link to our pretty links control panel, it displayed Link created, when I tried to test the link, it failed, so I looked at the error log

    And i notice the below error

    WordPress database error Unknown column ‘sponsored’ in ‘field list’ for query INSERT INTO wp_prli_links (redirect_type, url, slug, name, description, group_id, nofollow, sponsored, param_forwarding, track_me, link_cpt_id, updated_at, created_at) VALUES (‘307’, ‘https://www.mackrell.com/’, ‘mackrell-Landlord-laywers-mpu’, ‘Mackrell – 02-20 – MPU’, ”, NULL, ‘0’, ‘0’, ‘0’, ‘1’, ‘26643’, ‘2020-02-25 17:07:03’, ‘2020-02-25 17:07:03’) /* From [residentiallandlord.com/wp-admin/post.php] in [/nas/content/live/rlcom/wp-content/plugins/pretty-link/app/models/PrliLink.php:68] */ made by edit_post, wp_update_post, wp_insert_post, do_action(‘save_post’), WP_Hook->do_action, WP_Hook->apply_filters, PrliLinksController->save_cpt_link, PrliLink->create, referer: https://residentiallandlord.com/wp-admin/post-new.php?post_type=pretty-link&wp-post-new-reload=true

    Can you shed any light on how i fix this, I have tried de-activating and re-activating the plugin.

    We are only running th basic version.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author cartpauj

    (@cartpauj)

    It sound like the database upgrade script didn’t run successfully after the last update.

    Do you have access to your database via phpMyAdmin or something similar?

    If so, or if your webhost can help, do the following
    find these rows in wp_options table and set them all to 1

    prli_db_version
    prlipro_db_version
    prli_version

    After they’ve been set to 1 visit your wordpress dashboard and refresh it.

    That should force the database upgrade script to run again and hopefully will fix this error.

    Plugin Author cartpauj

    (@cartpauj)

    If you’re using the free version of Pretty Links, then you won’t have the prlipro_db_version. So just the other two will need to be updated.

    Thread Starter solarblitz77

    (@solarblitz77)

    I have just tried that, and the prli_version change the option_value to 3.1.0 after the refresh how ever, the pri_db_version remained at 1.

    Is there another way to force the database to upgrade

    As after it displayed the pretty-link-update, I tried to add a new link and got the following error

    [Thu Feb 27 11:11:35.130816 2020] [php7:notice] [pid 21995] [client 86.137.62.130:31820] WordPress database error Unknown column ‘sponsored’ in ‘field list’ for query INSERT INTO wp_prli_links (redirect_type, url, slug, name, description, group_id, nofollow, sponsored, param_forwarding, track_me, link_cpt_id, updated_at, created_at) VALUES (‘307’, ‘https://www.mackrell.com/’, ‘mackrell-Landlord-laywers-mpu’, ‘Mackrell – 02-20 – MPU’, ”, NULL, ‘1’, ‘0’, ‘0’, ‘1’, ‘26655’, ‘2020-02-27 11:11:35’, ‘2020-02-27 11:11:35’) /* From [residentiallandlord.com/wp-admin/post.php] in [/nas/content/live/rlcom/wp-content/plugins/pretty-link/app/models/PrliLink.php:68] */ made by edit_post, wp_update_post, wp_insert_post, do_action(‘save_post’), WP_Hook->do_action, WP_Hook->apply_filters, PrliLinksController->save_cpt_link, PrliLink->create, referer: https://residentiallandlord.com/wp-admin/post-new.php?post_type=pretty-link&wp-post-new-reload=true

    Plugin Author cartpauj

    (@cartpauj)

    Pretty Links runs the database script automatically when the /wp-admin/ is loaded if the prli_db_version is < the current db version.

    Since it remained at 1 after you changed it, it sounds like an error is happening when the database script is running (different error than the above).

    See if your webhost can check the database error logs for your site concerning pretty links (prli) and see if there’s any other errors.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Can’t create links WordPress Database Error’ is closed to new replies.