{"id":1285288,"date":"2017-05-17T20:58:13","date_gmt":"2017-05-18T03:58:13","guid":{"rendered":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/"},"modified":"2017-05-30T14:07:56","modified_gmt":"2017-05-30T21:07:56","slug":"database-error-in-photo-view","status":"closed","type":"topic","link":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/","title":{"rendered":"Database error in Photo View"},"content":{"rendered":"<p>Our Calendar default view is &#8220;Photo&#8221; from Events Calendar Pro. Loading that page throws off the following DB error in Query Monitor. Looks like a typo somewhere, though I haven&#8217;t found it just yet<\/p>\n<p>SELECT SQL_CALC_FOUND_ROWS *<br \/>\nFROM ( ) a<br \/>\nGROUP BY IF( post_parent = 0, ID, post_parent )<br \/>\nORDER BY EventStartDate ASC<br \/>\nWP_Query-&gt;get_posts()<br \/>\nwp-includes\/class-wp-query.php:2846<br \/>\nWP_Query-&gt;query()<br \/>\nwp-includes\/class-wp-query.php:3238<br \/>\nWP_Query-&gt;__construct()<br \/>\nwp-includes\/class-wp-query.php:3347<br \/>\nTribe__Events__Query::getEvents()<br \/>\nwp-content\/plugins\/the-events-calendar\/src\/Tribe\/Query.php:1017<br \/>\ntribe_get_events()<br \/>\nwp-content\/plugins\/the-events-calendar\/src\/functions\/template-tags\/general.php:218<br \/>\ntribe_has_previous_event()<br \/>\nwp-content\/plugins\/the-events-calendar\/src\/functions\/template-tags\/loop.php:236<br \/>\ntribe_get_template_part()<br \/>\nwp-content\/plugins\/the-events-calendar\/src\/functions\/template-tags\/general.php:131<br \/>\ntribe_get_template_part()<br \/>\nwp-content\/plugins\/the-events-calendar\/src\/functions\/template-tags\/general.php:131<br \/>\ntribe_get_view()<br \/>\nwp-content\/plugins\/the-events-calendar\/src\/functions\/template-tags\/general.php:45<br \/>\nTribe__Events__Templates::load_ecp_into_page_template()<br \/>\nwp-content\/plugins\/the-events-calendar\/src\/Tribe\/Templates.php:478<br \/>\napply_filters(&#8216;the_content&#8217;)<br \/>\nwp-includes\/plugin.php:203<br \/>\nthe_content()<br \/>\nwp-includes\/post-template.php:240<br \/>\nload_template(&#8216;~\/wp-content\/themes\/geekwire\/templates\/content-page.php&#8217;)<br \/>\nwp-includes\/template.php:686<br \/>\nlocate_template()<br \/>\nwp-includes\/template.php:643<br \/>\nget_template_part(&#8216;templates\/content&#8217;,&#8217;page&#8217;)<br \/>\nwp-includes\/general-template.php:167<br \/>\nPlugin: the-events-calendar 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 &#8216;) a GROUP BY IF( post_parent = 0, ID, post_parent ) ORDER BY EventStartDat&#8217; at line 5<\/p>\n","protected":false},"template":"","class_list":["post-1285288","topic","type-topic","status-closed","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Database error in Photo View -<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Database error in Photo View -\" \/>\n<meta property=\"og:description\" content=\"Our Calendar default view is &#8220;Photo&#8221; from Events Calendar Pro. Loading that page throws off the following DB error in Query Monitor. Looks like a typo somewhere, though I haven&#8217;t found it just yet SELECT SQL_CALC_FOUND_ROWS * FROM ( ) a GROUP BY IF( post_parent = 0, ID, post_parent ) ORDER BY EventStartDate ASC WP_Query-&gt;get_posts() [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/\" \/>\n<meta property=\"article:modified_time\" content=\"2017-05-30T21:07:56+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/\",\"url\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/\",\"name\":\"Database error in Photo View -\",\"isPartOf\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\"},\"datePublished\":\"2017-05-18T03:58:13+00:00\",\"dateModified\":\"2017-05-30T21:07:56+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/theeventscalendar.com\/support\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Topics\",\"item\":\"https:\/\/theeventscalendar.com\/support\/topics\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Calendar Products\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Events Calendar PRO\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/events-calendar-pro\/\"},{\"@type\":\"ListItem\",\"position\":5,\"name\":\"Database error in Photo View\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\",\"url\":\"https:\/\/theeventscalendar.com\/support\/\",\"name\":\"\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/theeventscalendar.com\/support\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Database error in Photo View -","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/","og_locale":"en_US","og_type":"article","og_title":"Database error in Photo View -","og_description":"Our Calendar default view is &#8220;Photo&#8221; from Events Calendar Pro. Loading that page throws off the following DB error in Query Monitor. Looks like a typo somewhere, though I haven&#8217;t found it just yet SELECT SQL_CALC_FOUND_ROWS * FROM ( ) a GROUP BY IF( post_parent = 0, ID, post_parent ) ORDER BY EventStartDate ASC WP_Query-&gt;get_posts() [&hellip;]","og_url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/","article_modified_time":"2017-05-30T21:07:56+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/","url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/","name":"Database error in Photo View -","isPartOf":{"@id":"https:\/\/theeventscalendar.com\/support\/#website"},"datePublished":"2017-05-18T03:58:13+00:00","dateModified":"2017-05-30T21:07:56+00:00","breadcrumb":{"@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/database-error-in-photo-view\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/theeventscalendar.com\/support\/"},{"@type":"ListItem","position":2,"name":"Topics","item":"https:\/\/theeventscalendar.com\/support\/topics\/"},{"@type":"ListItem","position":3,"name":"Calendar Products","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/"},{"@type":"ListItem","position":4,"name":"Events Calendar PRO","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/events\/events-calendar-pro\/"},{"@type":"ListItem","position":5,"name":"Database error in Photo View"}]},{"@type":"WebSite","@id":"https:\/\/theeventscalendar.com\/support\/#website","url":"https:\/\/theeventscalendar.com\/support\/","name":"","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/theeventscalendar.com\/support\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1285288","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":1,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1285288\/revisions"}],"predecessor-version":[{"id":1286198,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1285288\/revisions\/1286198"}],"wp:attachment":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/media?parent=1285288"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}