WordPress.org

Ready to get started?Download WordPress

Forums

How to unschedule a draft (2 posts)

  1. Dominor Novus
    Member
    Posted 1 year ago #

    I have a draft with a scheduled date for publishing.

    I need to remove the scheduled date (which is the default state of any draft).

    The only option I have is to change the date:

    Post editor > "Publish" meta box > "Publish on" field

    Pushing the date backwards or forwards is not viable solution for my requirements.

    I'm experienced with the back-end WordPress databases.

    Does anyone have a solution for unscheduling drafts?

  2. timbonicus
    Member
    Posted 10 months ago #

    A bit late to help Dominor I'm sure, but in case anyone else came across this post in a Google search like me...

    The wp_posts post_date_gmt column is the scheduled date. It defaults to '0000-00-00 00:00:00' which means 'publish immediately'. If you have a draft with a scheduled date that you want to remove, update this column to the default:

    update wp_posts set post_date_gmt='0000-00-00 00:00:00' where ID=<your post ID>

    One way to find the post ID is to search by title:
    select ID, post_date, post_date_gmt, post_title, post_status from wp_posts where post_title like '%Keyword%' and post_status='draft'

    Where Keyword is something from your title.

Topic Closed

This topic has been closed to new replies.

About this Topic