wp_foxlms_coupons

Static

Stores foxlms coupons data created by this plugin.

Column Definitions

ColumnTypeNullable
🔑idbigint(20) unsignedNO
titlevarchar(255)NO
codevarchar(50)NO
discount_typevarchar(20)NO
discount_amountdecimal(11,2)NO
usage_limit_totalint(11)NO
usage_limit_per_userint(11)YES
usage_countint(11)NO
applies_tovarchar(1000)YES
start_datedatetimeYES
end_datedatetimeYES
created_atdatetimeNO

CREATE TABLE Statement

CREATE TABLE `wp_foxlms_coupons` ( `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT, `title` varchar(255) NOT NULL, `code` varchar(50) NOT NULL, `discount_type` varchar(20) NOT NULL DEFAULT 'percentage', `discount_amount` decimal(11,2) NOT NULL DEFAULT '0', `usage_limit_total` int(11) NOT NULL DEFAULT '0', `usage_limit_per_user` int(11) DEFAULT NULL, `usage_count` int(11) NOT NULL DEFAULT '0', `applies_to` varchar(1000) DEFAULT NULL, `start_date` datetime DEFAULT NULL, `end_date` datetime DEFAULT NULL, `created_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (`id`), UNIQUE KEY `code` (`code`), KEY `discount_type` (`discount_type`), KEY `start_date` (`start_date`), KEY `end_date` (`end_date`), KEY `active_coupons` (`start_date`, `end_date`) ) $charset_collate;"; $results = $wpdb->get_results( $wpdb->prepare( "SELECT * FROM INFORMATION_SCHEMA.TABLES WHERE table_schema = %s AND table_name = 'wp_foxlms_coupons' ", DB_NAME ) );

Safe to delete?

If you have uninstalled Fox LMS – eLearning & Course Builder, 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_foxlms_coupons`;

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

Other tables from Fox LMS – eLearning & Course Builder