wp_mapsmith_businesses

Static

Stores mapsmith businesses data created by this plugin.

Column Definitions

ColumnTypeNullable
🔑idbigint(20) unsignedNO
namevarchar(255)NO
descriptiontextYES
pin_icon_urlvarchar(500)YES
pin_colorvarchar(20)YES
pin_scaledecimal(3,2)YES
pin_shapevarchar(20)YES
pin_stroke_colorvarchar(20)YES
pin_stroke_widthdecimal(3,1)YES
pin_shadowtinyint(1)YES
pin_shadow_sizedecimal(3,1)YES
timezonevarchar(100)YES
sort_orderint(11)YES
created_atdatetimeNO
updated_atdatetimeNO
business_idbigint(20) unsignedNO
namevarchar(255)NO
addressvarchar(500)YES
latdecimal(10,7)YES
lngdecimal(10,7)YES
cityvarchar(255)YES
statevarchar(100)YES
zipvarchar(20)YES
countryvarchar(100)YES
phonevarchar(50)YES
hourstextYES
websitevarchar(500)YES
custom_fieldstextYES
location_type_idbigint(20) unsignedYES
timezonevarchar(100)YES
photo_urlvarchar(500)YES
is_enabledtinyint(1)YES
sort_orderint(11)YES
created_atdatetimeNO
updated_atdatetimeNO
namevarchar(255)NO
center_latdecimal(10,7)YES
center_lngdecimal(10,7)YES
zoom_levelint(3)YES
map_theme_keyvarchar(100)YES
map_theme_jsonlongtextYES
pin_color_overridevarchar(20)YES
pin_icon_url_overridevarchar(500)YES
sidebar_fieldstextYES
popover_fieldstextYES
address_fieldstextYES
sidebar_positionvarchar(20)YES
map_heightvarchar(50)YES
auto_fit_boundstinyint(1)YES
cluster_pinstinyint(1)YES
search_enabledtinyint(1)YES
sidebar_modevarchar(20)YES
sidebar_overlay_max_heightvarchar(50)YES
sidebar_overlay_radiusvarchar(20)YES
sidebar_overlay_paddingvarchar(20)YES
container_radiusvarchar(20)YES
show_zoom_controltinyint(1)YES
show_map_type_controltinyint(1)YES
show_street_view_controltinyint(1)YES
show_fullscreen_controltinyint(1)YES
scroll_to_zoomtinyint(1)YES
photo_layoutvarchar(20)YES
hours_formatvarchar(20)YES
day_formatvarchar(20)YES
time_formatvarchar(10)YES
show_timezonetinyint(1)YES
show_sidebartinyint(1)YES
sidebar_shrink_to_fittinyint(1)YES
show_location_type_filtertinyint(1)YES
show_geolocation_buttontinyint(1)YES
show_open_badgetinyint(1)YES
open_badge_textvarchar(100)YES
custom_hours_templatevarchar(200)YES
custom_hours_closed_templatevarchar(200)YES
custom_csslongtextYES
created_atdatetimeNO
updated_atdatetimeNO
namevarchar(255)NO
business_idbigint(20) unsignedYES
sort_orderint(11)YES
created_atdatetimeNO
updated_atdatetimeNO
map_idbigint(20) unsignedNO
business_idbigint(20) unsignedNO
location_idbigint(20) unsignedNO

CREATE TABLE Statement

CREATE TABLE wp_mapsmith_businesses ( id bigint(20) unsigned NOT NULL AUTO_INCREMENT, name varchar(255) NOT NULL, description text DEFAULT '', pin_icon_url varchar(500) DEFAULT '', pin_color varchar(20) DEFAULT '#E53E3E', pin_scale decimal(3,2) DEFAULT 1.00, pin_shape varchar(20) DEFAULT 'default', pin_stroke_color varchar(20) DEFAULT '', pin_stroke_width decimal(3,1) DEFAULT 0.0, pin_shadow tinyint(1) DEFAULT 1, pin_shadow_size decimal(3,1) DEFAULT 3.0, timezone varchar(100) DEFAULT '', sort_order int(11) DEFAULT 0, created_at datetime DEFAULT '0000-00-00 00:00:00' NOT NULL, updated_at datetime DEFAULT '0000-00-00 00:00:00' NOT NULL, PRIMARY KEY (id) ) $charset_collate;"; // Locations table. $sql[] = "CREATE TABLE wp_mapsmith_locations ( id bigint(20) unsigned NOT NULL AUTO_INCREMENT, business_id bigint(20) unsigned NOT NULL, name varchar(255) NOT NULL, address varchar(500) DEFAULT '', lat decimal(10,7) DEFAULT 0.0000000, lng decimal(10,7) DEFAULT 0.0000000, city varchar(255) DEFAULT '', state varchar(100) DEFAULT '', zip varchar(20) DEFAULT '', country varchar(100) DEFAULT '', phone varchar(50) DEFAULT '', hours text DEFAULT '', website varchar(500) DEFAULT '', custom_fields text DEFAULT '', location_type_id bigint(20) unsigned DEFAULT NULL, timezone varchar(100) DEFAULT '', photo_url varchar(500) DEFAULT '', is_enabled tinyint(1) DEFAULT 1, sort_order int(11) DEFAULT 0, created_at datetime DEFAULT '0000-00-00 00:00:00' NOT NULL, updated_at datetime DEFAULT '0000-00-00 00:00:00' NOT NULL, PRIMARY KEY (id), KEY business_id (business_id), KEY is_enabled (is_enabled) ) $charset_collate;"; // Maps table. $sql[] = "CREATE TABLE wp_mapsmith_maps ( id bigint(20) unsigned NOT NULL AUTO_INCREMENT, name varchar(255) NOT NULL, center_lat decimal(10,7) DEFAULT 39.8283000, center_lng decimal(10,7) DEFAULT -98.5795000, zoom_level int(3) DEFAULT 4, map_theme_key varchar(100) DEFAULT 'default', map_theme_json longtext DEFAULT '', pin_color_override varchar(20) DEFAULT '', pin_icon_url_override varchar(500) DEFAULT '', sidebar_fields text DEFAULT '', popover_fields text DEFAULT '', address_fields text DEFAULT '', sidebar_position varchar(20) DEFAULT 'left', map_height varchar(50) DEFAULT '600px', auto_fit_bounds tinyint(1) DEFAULT 1, cluster_pins tinyint(1) DEFAULT 0, search_enabled tinyint(1) DEFAULT 1, sidebar_mode varchar(20) DEFAULT 'beside', sidebar_overlay_max_height varchar(50) DEFAULT '400px', sidebar_overlay_radius varchar(20) DEFAULT '12px', sidebar_overlay_padding varchar(20) DEFAULT '16px', container_radius varchar(20) DEFAULT '8px', show_zoom_control tinyint(1) DEFAULT 1, show_map_type_control tinyint(1) DEFAULT 0, show_street_view_control tinyint(1) DEFAULT 0, show_fullscreen_control tinyint(1) DEFAULT 1, scroll_to_zoom tinyint(1) DEFAULT 1, photo_layout varchar(20) DEFAULT 'full', hours_format varchar(20) DEFAULT 'smart', day_format varchar(20) DEFAULT 'short', time_format varchar(10) DEFAULT '12h', show_timezone tinyint(1) DEFAULT 1, show_sidebar tinyint(1) DEFAULT 1, sidebar_shrink_to_fit tinyint(1) DEFAULT 0, show_location_type_filter tinyint(1) DEFAULT 0, show_geolocation_button tinyint(1) DEFAULT 0, show_open_badge tinyint(1) DEFAULT 0, open_badge_text varchar(100) DEFAULT 'Open', custom_hours_template varchar(200) DEFAULT '', custom_hours_closed_template varchar(200) DEFAULT '', custom_css longtext DEFAULT NULL, created_at datetime DEFAULT '0000-00-00 00:00:00' NOT NULL, updated_at datetime DEFAULT '0000-00-00 00:00:00' NOT NULL, PRIMARY KEY (id) ) $charset_collate;"; // Location Types table. $sql[] = "CREATE TABLE wp_mapsmith_location_types ( id bigint(20) unsigned NOT NULL AUTO_INCREMENT, name varchar(255) NOT NULL, business_id bigint(20) unsigned DEFAULT NULL, sort_order int(11) DEFAULT 0, created_at datetime DEFAULT '0000-00-00 00:00:00' NOT NULL, updated_at datetime DEFAULT '0000-00-00 00:00:00' NOT NULL, PRIMARY KEY (id), KEY business_id (business_id) ) $charset_collate;"; // Map-Locations junction table. $sql[] = "CREATE TABLE wp_mapsmith_map_locations ( id bigint(20) unsigned NOT NULL AUTO_INCREMENT, map_id bigint(20) unsigned NOT NULL, business_id bigint(20) unsigned NOT NULL, location_id bigint(20) unsigned NOT NULL, PRIMARY KEY (id), UNIQUE KEY map_business_location (map_id, business_id, location_id) ) $charset_collate;"; require_once ABSPATH . 'wp-admin/includes/upgrade.php'; dbDelta( implode( "\n", $sql ) );

Safe to delete?

If you have uninstalled Mapsmith, 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_mapsmith_businesses`;

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

Other tables from Mapsmith