Reply To: Products from one category only

#6711
Wesley McDermott
Wesley McDermott
Participant

Hi Ernest,

I have updated and been running the new version of the plugin now for over a week and my host is still saying the problem persists. They sent me the following message:

We see that the same query continues to executes.
Because it is heavy for the Mysql server and it need unusual long time to execute and it can lead to 503 errors.

Here it is the query and you can see that after 9 seconds it is still executing. And along with it there is another one similar to this which stays for 5 seconds.

==============================================

1789658 haunted localhost haunted_haunted Query 00:00:09 SELECT wp_posts.post_title as title, wp_posts.ID as id, wp_posts.post_date as date, wp_posts.post_content as content, wp_posts.post_excerpt as excerpt, wp_users.user_nicename as author, wp_posts.post_type as post_type, (SELECT DISTINCT CONCAT(‘–‘, GROUP_CONCAT( wp_term_taxonomy.term_id SEPARATOR ‘—-‘ ), ‘–‘) FROM wp_term_taxonomy LEFT JOIN wp_term_relationships ON wp_term_relationships.term_taxonomy_id = wp_term_taxonomy.term_taxonomy_id WHERE (wp_term_relationships.object_id = wp_posts.ID) ) as ttid, ((case when (lower(wp_posts.post_title) REGEXP ‘rugby|hotel|hall’) then 10 else 0 end) + (case when (lower(wp_posts.post_content) REGEXP ‘hotel|brownsover|hall|warwick|ideal|available|upon|avon|stratford|rugby’) then 8 else 0 end)) as relevance FROM wp_posts LEFT JOIN wp_postmeta ON wp_postmeta.post_id = wp_posts.ID LEFT JOIN wp_users ON wp_users.ID = wp_posts.post_author WHERE (wp_posts.ID <> 379) AND (wp_posts.post_
type
REGEXP ‘[[:<:]]dummy_notting[[:>:]]|[[:<:]]post[[:>:]]|[[:<:]]product[[:>:]]’) AND wp_posts.ID NOT IN (-99) AND (wp_posts.post_status = ‘publish’) AND ((lower(wp_posts.post_title) REGEXP ‘rugby|hotel|hall’) OR (lower(wp_posts.post_content) REGEXP ‘rugby|hotel|hall’) OR (lower(wp_posts.post_content) REGEXP ‘hotel|brownsover|hall|warwick|ideal|available|upon|avon|stratford|rugby’) OR (lower(wp_posts.post_title) REGEXP ‘hotel|brownsover|hall|warwick|ideal|available|upon|avon|stratford|rugby’)) GROUP BY wp_posts.ID HAVING (ttid NOT REGEXP
‘–344–|–325–|–326–|–327–|–328–|–329–|–330–|–331–|–332–|–333–|–334–|–335–|–336–|–337–|–338–|–339–|–340–|–341–|–342–|–343–|–345–|–346–|–347–|–355–|–356–|–357–|–358–|–359–|–365–|–366–|–360–|–361–|–362–|–363–|–367–|–368–|–369–|–370–|–371–|–372–|–373–|–374–|–375–|–376–|–377–|–378–|–379–|–380–|–381–|–382–|–383–|–384–|–385–|–386–|–388–|–389–|–390–|–393–|–394–|–395–|–396–|–397–|–398–|–399–|–400–|–401–|–402–|–404–|–406–|–408–|–409–|–411–|–412–|–460–|–413–|–414–|–416–|–418–|–419–|–420–|–421–|–422–|–424–|–425–|–448–|–449–|–426–|–427–|–428–|–429–|–430–|–431–|–432–|–433–|–436–|–437–|–439–|–440–|–450–|–441–|–451–|–442–|–443–|–444–|–445–|–446–|–452–|–453–|–454–|–456–|–457–|–458–|–459–|–465–|–461–|–462–|–463–|–464–|–467–|–469–|–470–|–471–|–472–|–473
–|–47
5–|–476–|–477–|–478–|–479–|–480–|–364–|–482–|–483–|–484–|–485–|–486–|–487–|–489–|–490–|–491–|–492–|–494–|–495–|–496–|–497–|–498–|–499–|–500–|–501–|–502–|–503–|–504–|–505–|–507–|–508–|–509–|–513–|–510–|–514–|–511–|–512–‘) AND (ttid REGEXP ‘–298–‘) ORDER BY relevance DESC, wp_posts.post_date DESC LIMIT 3