Autoship schedules database table
Autoship Schedules
Autoship Schedules are stored in the WC Autoship Schedules database table.
SELECT * FROM wp_wc_autoship_schedules;
The WC Autoship Schedule stores important information for a customer's recurring order, such as frequency, next order date, shipping method, and payment method. The structure of the wp_wc_autoship_schedules table is shown below:
| Column | Value | Description |
| id | integer, auto-increment | Primary key |
| customer_id | Wordpress User ID | Customer ID |
| autoship_frequency | 7 - 365 | Autoship Frequency |
| autoship_status | 0 (paused), 1 (active) | Autoship Status |
| last_order_date | MySQL Date | Last Order Date |
| next_order_date | MySQL Date | Next Order Date |
| shipping_method_id | WooCommerce Shipping Method ID | Shipping Method ID |
| payment_token_id | WooCommerce Payment Token ID |
Payment Token ID |
| coupon | WooCommerce coupon code | Coupon |
The items for an Autoship Schedule are stored in the related table wp_wc_autoship_schedule_items.
SELECT * FROM wp_wc_autoship_schedule_items;
The structure of the wp_wc_autoship_schedule_items table is shown below:
| Column | Value | Description |
| id | integer, auto-increment | Primary key |
| schedule_id | WC Autoship Schedule ID | Parent Autoship Schedule ID |
| product_id | WooCommerce Product ID | Product ID |
| variation_id | WooCommerce Product Variation ID | Product Variation ID |
| qty | integer | Quantity |