wp_tutor_carts

Static

Stores tutor carts data created by this plugin.

Column Definitions

ColumnTypeNullable
🔑idBIGINT(20) UNSIGNEDNO
user_idBIGINT(20) UNSIGNEDYES
coupon_codeVARCHAR(50)YES
created_at_gmtDATETIMENO
updated_at_gmtDATETIMEYES
cart_idBIGINT(20) UNSIGNEDNO
course_idBIGINT(20) UNSIGNEDNO
user_idBIGINT(20) UNSIGNEDYES
billing_first_nameVARCHAR(255)NO
billing_last_nameVARCHAR(255)NO
billing_emailVARCHAR(255)NO
billing_phoneVARCHAR(20)NO
billing_zip_codeVARCHAR(20)NO
billing_addressTEXTNO
billing_countryVARCHAR(100)NO
billing_stateVARCHAR(100)NO
billing_cityVARCHAR(100)NO

CREATE TABLE Statement

CREATE TABLE wp_tutor_carts ( id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, user_id BIGINT(20) UNSIGNED DEFAULT NULL, coupon_code VARCHAR(50) DEFAULT NULL, created_at_gmt DATETIME NOT NULL, updated_at_gmt DATETIME, PRIMARY KEY (id), KEY user_id (user_id), KEY coupon_code (coupon_code), CONSTRAINT fk_tutor_cart_user_id FOREIGN KEY (user_id) REFERENCES wp_users(ID) ON DELETE CASCADE ) $charset_collate;"; $cart_items_table = "CREATE TABLE wp_tutor_cart_items ( id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, cart_id BIGINT(20) UNSIGNED NOT NULL, course_id BIGINT(20) UNSIGNED NOT NULL, PRIMARY KEY (id), KEY cart_id (cart_id), KEY course_id (course_id), CONSTRAINT fk_tutor_cart_item_cart_id FOREIGN KEY (cart_id) REFERENCES wp_tutor_carts(id) ON DELETE CASCADE, CONSTRAINT fk_tutor_cart_item_course_id FOREIGN KEY (course_id) REFERENCES wp_posts(ID) ON DELETE CASCADE ) $charset_collate;"; $customer_table = "CREATE TABLE wp_tutor_customers ( id BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, user_id BIGINT(20) UNSIGNED DEFAULT NULL, billing_first_name VARCHAR(255) NOT NULL, billing_last_name VARCHAR(255) NOT NULL, billing_email VARCHAR(255) NOT NULL, billing_phone VARCHAR(20) NOT NULL, billing_zip_code VARCHAR(20) NOT NULL, billing_address TEXT NOT NULL, billing_country VARCHAR(100) NOT NULL, billing_state VARCHAR(100) NOT NULL, billing_city VARCHAR(100) NOT NULL, PRIMARY KEY (id), KEY user_id (user_id), KEY billing_email (billing_email) ) $charset_collate;"; require_once ABSPATH . 'wp-admin/includes/upgrade.php'; dbDelta( $quiz_attempts_sql );

Safe to delete?

If you have uninstalled Tutor LMS – eLearning and online course solution, this table is generally safe to remove. However, always back up your database first.

Note: Some plugins share tables or are dependencies of other plugins. Verify nothing else depends on this table before dropping it.

How to remove this table

DROP TABLE IF EXISTS `wp_tutor_carts`;

Run this query using phpMyAdmin, Adminer, or your MySQL client. Back up first.

Other tables from Tutor LMS – eLearning and online course solution