Skip to content

Instantly share code, notes, and snippets.

@kimwhite
Forked from ideadude/pmpro_set_enddates.sql
Last active May 16, 2022 13:35
Show Gist options
  • Save kimwhite/4ba73d0e155238c003f9888c927d951d to your computer and use it in GitHub Desktop.
Save kimwhite/4ba73d0e155238c003f9888c927d951d to your computer and use it in GitHub Desktop.
Set an enddate for active subscriptions with PMPro
# BACKUP FIRST
# This SQL query will set the expiration date
# to 2023-02-01 for ALL active membership including users with active subscriptions who are marked NEVER.
# a different current enddate.
# BACKUP FIRST
UPDATE wp_pmpro_memberships_users
SET enddate = '2023-02-01 00:00:00'
WHERE status = 'active'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment