Support

Home Forums Event Espresso Premium PHP Error (2)

PHP Error (2)

Posted: March 7, 2014 at 2:41 pm

Viewing 20 reply threads


Philip Shambrook

March 7, 2014 at 2:41 pm

I’ve been seeing regular PHO errors being flagged but haven’t thought much of it as I am still just working through things. Might be prudent to see if there is something amiss though. Here’s the most recent log:

[BPS Pro htaccess Protected Secure PHP Error Log]

[05-Mar-2014 17:12:30 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘146’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[06-Mar-2014 06:52:41 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘337’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[06-Mar-2014 07:03:08 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘157’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[06-Mar-2014 17:03:31 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘608’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[07-Mar-2014 08:42:31 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘5134’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[07-Mar-2014 14:15:59 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘220’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[07-Mar-2014 16:56:38 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘240’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[07-Mar-2014 20:40:27 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘146’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[07-Mar-2014 20:40:30 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘157’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[07-Mar-2014 20:40:32 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘337’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts


Philip Shambrook

March 7, 2014 at 2:43 pm

Hate it when I do that! Wodpress 3.8.1 and Event Espresso 4.1.8


Lorenzo Orlando Caum

  • Support Staff

March 7, 2014 at 3:01 pm

Hi Philip,

Is there any information available on what changes are been made when these are been logged?


Lorenzo


Philip Shambrook

March 15, 2014 at 10:17 pm

I am not doing anything with the plugin at present. It is active but not configured at all. The error message is there when I log into the website.


Josh

  • Support Staff

March 17, 2014 at 9:23 am

Hi Philip,

Can you let us know which other plugins you have installed on your site so we can investigate further?


Philip Shambrook

March 17, 2014 at 3:28 pm

Here you go –


Philip Shambrook

March 17, 2014 at 3:30 pm

Hmmm, maybe this’ll work


Philip Shambrook

March 17, 2014 at 3:31 pm

Screenshot


Sidney Harrell

March 17, 2014 at 4:59 pm

From the error, it looks like the post_type field is missing from your wp_posts table. That’s really odd, because it should have been created by WordPress when it was installed. Have you done anything to modify the database schema? Can you log into phpMyAdmin?


Philip Shambrook

March 17, 2014 at 6:37 pm

It is there, I’ve just looked.


Sidney Harrell

March 17, 2014 at 6:46 pm

Just read the error more carefully, and it looks like we might be hooking into the query when we are not supposed to. I know we addressed a similar problem recently in the 4.1.9 release. Have you tried updating to the 4.1.9.1.reg that is the most recent release?


Philip Shambrook

March 17, 2014 at 7:00 pm

It definitely is now as I’ve just done a complete uninstall, including dropping the SQL tables, and reinstalled 4.1.9.1.reg. I’ll leave it be for now as I don’t have time to do anything more for now. I’ll let you know if the error pops up again.
Thanks


Dean

March 18, 2014 at 12:28 am

Thanks Philip, please do keep us in the loop if this re-occurs.


Philip Shambrook

March 19, 2014 at 8:26 pm

New error message:

[BPS Pro htaccess Protected Secure PHP Error Log]

[19-Mar-2014 16:46:32 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘213’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[19-Mar-2014 17:06:59 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘157’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[20-Mar-2014 01:55:30 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘227’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts

The only thing I have done after reinstalling is make some changes to some elements of the General Settings.


Lorenzo Orlando Caum

  • Support Staff

March 20, 2014 at 7:42 am

Hi Philip,

I spent some time trying to duplicate this issue but I have not run into it. I’m running a vanilla install of WP along with EE 4.1.9.1 and I’ve adjusted various settings on the General Settings tab.

Do any of the plugins that you are using having an optimize feature for the database?

Also, could you share the name of the theme that you are using?


Lorenzo


Philip Shambrook

March 20, 2014 at 12:36 pm

The theme is Customizr

I don’t know if any of the plugins have an optimise feature for the the database. Looking at the database tables only BPS Pro, Contact Form and Event Espresso have added tables. Not sure of that is any help.


Lorenzo Orlando Caum

  • Support Staff

March 20, 2014 at 3:55 pm

Hi Philip,

Could you send over a temporary SFTP or FTP login so I can take a look with a developer?

https://eventespresso.com/send-login-details/


Lorenzo


Philip Shambrook

March 28, 2014 at 9:43 pm

Sadly it’s back:

[27-Mar-2014 07:31:18 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘608’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[27-Mar-2014 21:08:44 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘157’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[28-Mar-2014 11:06:36 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘189’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts
[28-Mar-2014 11:06:37 UTC] WordPress database error Unknown column ‘wp_posts.post_type’ in ‘where clause’ for query SELECT wp_comments.* FROM wp_comments WHERE comment_post_ID = ‘189’ AND comment_approved = ‘1’ AND wp_posts.post_type != ‘espresso_attendees’ ORDER BY comment_date_gmt DESC LIMIT 10 made by require(‘wp-blog-header.php’), wp, WP->main, WP->query_posts, WP_Query->query, WP_Query->get_posts


Lorenzo Orlando Caum

  • Support Staff

March 29, 2014 at 2:05 pm

Hello, I patched your file at the beginning of the week but if you recently updated, then it would have removed the patch.

This is in the 4.2 release which we are currently testing internally.


Lorenzo


Philip Shambrook

March 29, 2014 at 6:13 pm

That’s be right, as I applied an update that was notified. Are you able to send me the file that was patched? I can then put it back.


Lorenzo Orlando Caum

  • Support Staff

March 29, 2014 at 6:25 pm

Sure, here is the file:

http://cl.ly/code/1R430B1Y392a

It should go here:

wp-content/plugins/event-espresso-core-reg/modules/feeds/EED_Feeds.module.php


Lorenzo

Viewing 20 reply threads

The support post ‘PHP Error (2)’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso