• My hosting provider wants to suspend website due to slow queries. Here are they:

    Time running : 34
    Query : SELECT SQL_CALC_FOUND_ROWS wp_posts.ID FROM wp_posts LEFT JOIN wp_icl_translations t ON wp_posts.ID = t.element_id AND t.element_type LIKE ‘post\_%’ LEFT JOIN wp_icl_languages l ON t.language_code=l.code AND l.active=1 WHERE 1=1 AND (((wp_posts.post_title LIKE ‘%Europe%’) OR (wp_posts.post_excerpt LIKE ‘%Europe%’) OR (wp_posts.post_content LIKE ‘%Europe%’))) AND wp_posts.post_type IN (‘post’, ‘page’, ‘attachment’, ‘slides’, ‘careers’, ‘partners’, ‘team’, ‘news’, ‘casestudies’) AND (wp_posts.post_status = ‘publish’ OR wp_posts.post_author = 1 AND wp_posts.post_status = ‘private’) AND (t.language_code=’en’ OR t.language_code IS NULL ) ORDER BY wp_posts.post_title LIKE ‘%Europe%’ DESC, wp_posts.post_date DESC LIMIT 0, 10

    Time running : 50
    Query : SELECT SQL_CALC_FOUND_ROWS wp_posts.ID FROM wp_posts LEFT JOIN wp_icl_translations t ON wp_posts.ID = t.element_id AND t.element_type LIKE ‘post\_%’ LEFT JOIN wp_icl_languages l ON t.language_code=l.code AND l.active=1 WHERE 1=1 AND (((wp_posts.post_title LIKE ‘%1%’) OR (wp_posts.post_excerpt LIKE ‘%1%’) OR (wp_posts.post_content LIKE ‘%1%’))) AND (wp_posts.post_password = ”) AND wp_posts.post_type IN (‘post’, ‘page’, ‘attachment’, ‘slides’, ‘careers’, ‘partners’, ‘team’, ‘news’, ‘casestudies’, ‘privatearea’) AND (wp_posts.post_status = ‘publish’) AND (t.language_code=’en’ OR t.language_code IS NULL ) ORDER BY wp_posts.post_title LIKE ‘%1%’ DESC, wp_posts.post_date DESC LIMIT 0, 10

    Is there someone who knows how can I solve this issue ? How I see this query had been executed after using search form in website, right ?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Who is your web host? Also, which translation plugin are you using?

    Do you have problems with this queries too:
    SELECT ID, post_content, post_name, post_author, post_parent, post_date_gmt, post_date, post_date_gmt, post_title, post_type\n\t\t\t FROM wp_posts\n\t\t\t WHERE post_status=’publish’\n\t\t\t AND (DATEDIFF(CURDATE(), post_date_gmt)<=2)\n\t\t\t AND post_type IN (‘post’,’page’)\n\t\t\t ORDER BY post_date_gmt DESC\n\t\t\t LIMIT 0, 1\n\t\t

    and

    SELECT meta_key FROM wp_postmeta\n\t\t\t\tGROUP BY meta_key\n\t\t\t\tHAVING meta_key NOT LIKE ‘\\_%’ and meta_key NOT LIKE ‘field_%’\n\t\t\t\tORDER BY meta_key\n\t\t\t\tLIMIT 150

    Thread Starter Aida G

    (@aidag)

    My host is names.co.uk and I’m using WPML.

    You will be best suited contacting WPML Support
    https://wpml.org/forums/forum/english-support/

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Mysql slow queries issue’ is closed to new replies.