Title: WordPress Database Error
Last modified: February 29, 2020

---

# WordPress Database Error

 *  Resolved [DimaW](https://wordpress.org/support/users/dimaw/)
 * (@dimaw)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/wordpress-database-error-142/)
 * Hello, i found the following error in the debug.log of my site:
 *     ```
       WordPress-Datenbank-Fehler Unknown column 'EventStartDate' in 'order clause' für Abfrage SELECT SQL_CALC_FOUND_ROWS DISTINCT dr_posts.ID FROM dr_posts  LEFT JOIN dr_term_relationships ON (dr_posts.ID = dr_term_relationships.object_id) LEFT JOIN
        dr_postmeta as tribe_event_end_date ON ( dr_posts.ID = tribe_event_end_date.post_id AND tribe_event_end_date.meta_key = '_EventEndDate' )  WHERE 1=1  AND ( 
         dr_term_relationships.term_taxonomy_id IN (134,135,148)
   
       ) AND dr_posts.post_type = 'tribe_events' AND (dr_posts.post_status = 'publish' OR dr_posts.post_status = 'hidden' OR dr_posts.post_status = 'expired' OR 
       dr_posts.post_status = 'archived' OR dr_posts.post_status = 'tribe-ea-success' OR dr_posts.post_status = 'tribe-ea-failed' OR dr_posts.post_status = 'tribe-ea-schedule'
        OR dr_posts.post_status = 'tribe-ea-pending' OR dr_posts.post_status = 'tribe-ea-draft' 
       OR dr_posts.post_status = 'private') GROUP BY dr_posts.ID ORDER BY EventStartDate DESC, dr_posts.post_modified DESC LIMIT 0, 1 von require('wp-blog-header.php'), wp, WP->main,
        WP->query_posts, WP_Query->query, WP_Query->get_posts, do_action_ref_array('pre_get_posts'), WP_Hook->do_action, WP_Hook->apply_filters, 
       WPSEO_Sitemaps->redirect, WPSEO_Sitemaps->build_sitemap, WPSEO_Sitemaps->build_root_map, WPSEO_Taxonomy_Sitemap_Provider->get_index_links, WP_Query->__construct, WP_Query->query, WP_Query->get_posts
       ```
   
 * I am not sure if your Event Calendar Plugin creates this broken Query or the 
   Yoast Plugin. The Problem ist the “order by EventStartDate”, because it does 
   not exists.
 * I would be happy, if you can help me finding the source of this error 🙂
    -  This topic was modified 6 years, 3 months ago by [DimaW](https://wordpress.org/support/users/dimaw/).

Viewing 1 replies (of 1 total)

 *  [carlosonweb](https://wordpress.org/support/users/carlosonweb/)
 * (@carlosonweb)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/wordpress-database-error-142/#post-13138594)
 * I hope Tribe team can fix it, but you can also try the solution suggested here:
 * [https://wordpress.org/support/topic/unknown-column-eventstartdate-in-order-clause/#post-13138586](https://wordpress.org/support/topic/unknown-column-eventstartdate-in-order-clause/#post-13138586)

Viewing 1 replies (of 1 total)

The topic ‘WordPress Database Error’ is closed to new replies.

 * ![](https://ps.w.org/the-events-calendar/assets/icon-256x256.gif?rev=2516440)
 * [The Events Calendar](https://wordpress.org/plugins/the-events-calendar/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/the-events-calendar/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/the-events-calendar/)
 * [Active Topics](https://wordpress.org/support/plugin/the-events-calendar/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/the-events-calendar/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/the-events-calendar/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [carlosonweb](https://wordpress.org/support/users/carlosonweb/)
 * Last activity: [5 years, 10 months ago](https://wordpress.org/support/topic/wordpress-database-error-142/#post-13138594)
 * Status: resolved