wp_dgap_locations

Static

Stores dgap locations data created by this plugin.

Column Definitions

ColumnTypeNullable
🔑idBIGINT UNSIGNEDNO
nameVARCHAR(255)NO
addressTEXTYES
latitudeVARCHAR(50)YES
longitudeVARCHAR(50)YES
timezoneVARCHAR(100)YES
business_hoursLONGTEXTYES
statusTINYINTYES
created_atDATETIMEYES
updated_atDATETIMEYES
first_nameVARCHAR(150)NO
last_nameVARCHAR(150)YES
image_idBIGINT UNSIGNEDYES
descriptionTEXTYES
emailVARCHAR(255)YES
phone_dial_codeVARCHAR(10)YES
phoneVARCHAR(50)YES
statusTINYINTYES
created_atDATETIMEYES
updated_atDATETIMEYES
nameVARCHAR(255)NO
typeENUM('staff','service')NO
entity_idsLONGTEXTNO
datesLONGTEXTNO
statusTINYINT(1)YES
created_atDATETIMEYES
nameVARCHAR(255)NO
descriptionTEXTYES
durationINTNO
slot_stepINTYES
buffer_beforeINTYES
buffer_afterINTYES
daily_limitINTYES
advanced_bookingINTYES
priceDECIMAL(10,2)YES
statusTINYINTYES
created_atDATETIMEYES
updated_atDATETIMEYES
location_idBIGINT UNSIGNEDNO
service_idBIGINT UNSIGNEDNO
staff_idBIGINT UNSIGNEDNO
capacityINTYES
availabilityLONGTEXTNO
recurrence_typeVARCHAR(20)YES
repeat_intervalINTYES
date_startDATENO
date_endDATEYES
statusTINYINTYES
is_infiniteTINYINTYES
created_atDATETIMEYES
updated_atDATETIMEYES
user_idBIGINT UNSIGNEDYES
emailVARCHAR(190)NO
first_nameVARCHAR(100)NO
last_nameVARCHAR(100)YES
image_idBIGINT UNSIGNEDYES
phone_dial_codeVARCHAR(10)YES
phoneVARCHAR(50)YES
notesTEXTYES
statusTINYINTYES
created_atDATETIMEYES
updated_atDATETIMEYES
user_idBIGINT UNSIGNEDYES
schedule_idBIGINT UNSIGNEDNO
location_idBIGINT UNSIGNEDNO
service_idBIGINT UNSIGNEDNO
staff_idBIGINT UNSIGNEDNO
booking_dateDATENO
start_timeTIMENO
end_timeTIMENO
customer_idBIGINT UNSIGNEDNO
booking_noteTEXTYES
priceDECIMAL(10,2)YES
ip_addressVARCHAR(50)YES
custom_fieldsLONGTEXTYES
statusVARCHAR(20)YES
created_atDATETIMEYES
nameVARCHAR(255)NO
layoutVARCHAR(255)YES
settingsLONGTEXTYES
custom_fieldsLONGTEXTYES
statusTINYINTYES
created_atDATETIMEYES
updated_atDATETIMEYES

CREATE TABLE Statement

CREATE TABLE wp_dgap_locations ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, name VARCHAR(255) NOT NULL, address TEXT, latitude VARCHAR(50), longitude VARCHAR(50), timezone VARCHAR(100), business_hours LONGTEXT NULL, status TINYINT DEFAULT 1, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, updated_at DATETIME DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id) ) $charset;"; $tables['staff'] = "CREATE TABLE wp_dgap_staff ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, first_name VARCHAR(150) NOT NULL, last_name VARCHAR(150) NULL, image_id BIGINT UNSIGNED NULL, description TEXT, email VARCHAR(255), phone_dial_code VARCHAR(10) NULL, phone VARCHAR(50), status TINYINT DEFAULT 1, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, updated_at DATETIME DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id) ) $charset;"; $tables['timeoff'] = "CREATE TABLE wp_dgap_timeoff ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, name VARCHAR(255) NOT NULL, type ENUM('staff','service') NOT NULL, entity_ids LONGTEXT NOT NULL, dates LONGTEXT NOT NULL, status TINYINT(1) DEFAULT 1, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (id) ) $charset;"; $tables['services'] = "CREATE TABLE wp_dgap_services ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, name VARCHAR(255) NOT NULL, description TEXT, duration INT NOT NULL, slot_step INT, buffer_before INT, buffer_after INT, daily_limit INT, advanced_booking INT, price DECIMAL(10,2), status TINYINT DEFAULT 1, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, updated_at DATETIME DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id) ) $charset;"; $tables['schedules'] = "CREATE TABLE wp_dgap_schedules ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, location_id BIGINT UNSIGNED NOT NULL, service_id BIGINT UNSIGNED NOT NULL, staff_id BIGINT UNSIGNED NOT NULL, capacity INT DEFAULT 1, availability LONGTEXT NOT NULL, recurrence_type VARCHAR(20) DEFAULT 'weekly', repeat_interval INT DEFAULT 1, date_start DATE NOT NULL, date_end DATE NULL, status TINYINT DEFAULT 1, is_infinite TINYINT DEFAULT 0, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, updated_at DATETIME DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id), KEY location_id (location_id), KEY service_id (service_id), KEY staff_id (staff_id) ) $charset;"; $tables['customers'] = "CREATE TABLE wp_dgap_customers ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, user_id BIGINT UNSIGNED DEFAULT NULL, email VARCHAR(190) NOT NULL, first_name VARCHAR(100) NOT NULL, last_name VARCHAR(100) DEFAULT NULL, image_id BIGINT UNSIGNED NULL, phone_dial_code VARCHAR(10) DEFAULT NULL, phone VARCHAR(50), notes TEXT, status TINYINT DEFAULT 1, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, updated_at DATETIME DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id), UNIQUE KEY email (email), KEY user_id (user_id) ) $charset;"; $tables['bookings'] = "CREATE TABLE wp_dgap_bookings ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, user_id BIGINT UNSIGNED NULL, schedule_id BIGINT UNSIGNED NOT NULL, location_id BIGINT UNSIGNED NOT NULL, service_id BIGINT UNSIGNED NOT NULL, staff_id BIGINT UNSIGNED NOT NULL, booking_date DATE NOT NULL, start_time TIME NOT NULL, end_time TIME NOT NULL, customer_id BIGINT UNSIGNED NOT NULL, booking_note TEXT NULL, price DECIMAL(10,2) DEFAULT 0.00, ip_address VARCHAR(50) NULL, custom_fields LONGTEXT NULL, status VARCHAR(20) DEFAULT 'pending', created_at DATETIME DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (id), KEY user_id (user_id), KEY schedule_id (schedule_id), KEY customer_id (customer_id), KEY location_id (location_id), KEY service_id (service_id), KEY staff_id (staff_id), KEY status_date (status, booking_date) ) $charset;"; $tables['forms'] = "CREATE TABLE wp_dgap_forms ( id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, name VARCHAR(255) NOT NULL, layout VARCHAR(255), settings LONGTEXT NULL, custom_fields LONGTEXT NULL, status TINYINT DEFAULT 1, created_at DATETIME DEFAULT CURRENT_TIMESTAMP, updated_at DATETIME DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id) ) $charset;"; foreach ( $tables as $sql ) { dbDelta( $sql );

Safe to delete?

If you have uninstalled Digent Appointments, 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_dgap_locations`;

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

Other tables from Digent Appointments