Title: SQL error when no physical location
Last modified: January 6, 2020

---

# SQL error when no physical location

 *  Resolved [ecat](https://wordpress.org/support/users/ecat/)
 * (@ecat)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/sql-error-when-no-physical-location/)
 * I recently found errors written to the php error log as far back as March of 
   2019 which I have traced to coming from displaying an event when “no physical
   location” has been selected, but locations are allowed. The event displays correctly
   with “Map Unavailable”. No location_id is filled in to the query, hence the error.
   I am running WP 5.3.2, php 7.3.13, and Events Manager 5.9.7.1. However, back 
   when the error started, these were not the versions. Thank you for your help.
   
   The error is: WordPress database error You have an error in your SQL syntax; 
   check the manual that corresponds to your MySQL server version for the right 
   syntax to use near ” at line 1 for query SELECT location_name, location_address,
   location_town, location_state, location_postcode, location_region, location_country,
   location_latitude, location_longitude FROM xx_em_locations WHERE location_id 
   = made by require(‘wp-blog-header.php’), require_once(‘wp-includes/template-loader.
   php’), include(‘/themes/weaver-xtreme/single.php’), weaverx_page_tail, weaverx_get_footer,
   get_footer, locate_template, load_template, require_once(‘/themes/weaver-xtreme/
   footer.php’), wp_footer, do_action(‘wp_footer’), WP_Hook->do_action, WP_Hook-
   >apply_filters, {closure}

Viewing 1 replies (of 1 total)

 *  Plugin Support [angelo_nwl](https://wordpress.org/support/users/angelo_nwl/)
 * (@angelo_nwl)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/sql-error-when-no-physical-location/#post-12307566)
 * haven’t experienced this with the latest EM version, however, we will going to
   re-check this error and inform the devs if needed.

Viewing 1 replies (of 1 total)

The topic ‘SQL error when no physical location’ is closed to new replies.

 * ![](https://ps.w.org/events-manager/assets/icon-256x256.png?rev=3550347)
 * [Events Manager - Calendar, Bookings, Tickets, and more!](https://wordpress.org/plugins/events-manager/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/events-manager/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/events-manager/)
 * [Active Topics](https://wordpress.org/support/plugin/events-manager/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/events-manager/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/events-manager/reviews/)

## Tags

 * [sql-error](https://wordpress.org/support/topic-tag/sql-error/)

 * 1 reply
 * 2 participants
 * Last reply from: [angelo_nwl](https://wordpress.org/support/users/angelo_nwl/)
 * Last activity: [6 years, 4 months ago](https://wordpress.org/support/topic/sql-error-when-no-physical-location/#post-12307566)
 * Status: resolved