Support

Account

Home Forums ACF PRO Continuous loop in Relationship field with custom title + custom search Reply To: Continuous loop in Relationship field with custom title + custom search

  • Yup, there it was:

    [12-Jun-2016 19:57:05 UTC]  AND wp_posts.post_type = 'property' AND ((wp_posts.post_status <> 'trash' AND wp_posts.post_status <> 'auto-draft')) AND ( ( t.language_code = 'pt-pt' AND wp_posts.post_type  IN ('post','page','acf-field-group','acf-field','property','testimonial' )  ) OR wp_posts.post_type  NOT  IN ('post','page','acf-field-group','acf-field','property','testimonial' )  )wp_posts.post_date DESCLIMIT 40, 20 JOIN wp_icl_translations t
    							ON wp_posts.ID = t.element_id
    								AND t.element_type = CONCAT('post_', wp_posts.post_type)  INNER JOIN wp_postmeta as METACF ON (wp_posts.ID = METACF.post_id)
    [12-Jun-2016 19:57:05 UTC]  AND wp_posts.post_type = 'property' AND ((wp_posts.post_status <> 'trash' AND wp_posts.post_status <> 'auto-draft')) AND ( ( t.language_code = 'pt-pt' AND wp_posts.post_type  IN ('post','page','acf-field-group','acf-field','property','testimonial' )  ) OR wp_posts.post_type  NOT  IN ('post','page','acf-field-group','acf-field','property','testimonial' )  )wp_posts.post_date DESC JOIN wp_icl_translations t
    							ON wp_posts.ID = t.element_id
    								AND t.element_type = CONCAT('post_', wp_posts.post_type)  

    And this is doing a query with the word “test”, which should return at least 4 results and it returns only the first one:

    [12-Jun-2016 20:06:27 UTC]  AND (((wp_posts.post_title LIKE '%test%') OR (wp_posts.post_excerpt LIKE '%test%') OR (wp_posts.post_content LIKE '%test%') OR (METACF.meta_key = 'estate_property_id' AND CAST(METACF.meta_value AS CHAR) LIKE '%test%')))  AND wp_posts.post_type = 'property' AND ((wp_posts.post_status <> 'trash' AND wp_posts.post_status <> 'auto-draft')) AND ( ( t.language_code = 'pt-pt' AND wp_posts.post_type  IN ('post','page','acf-field-group','acf-field','property','testimonial' )  ) OR wp_posts.post_type  NOT  IN ('post','page','acf-field-group','acf-field','property','testimonial' )  )wp_posts.post_date DESCLIMIT 0, 20 JOIN wp_icl_translations t
    							ON wp_posts.ID = t.element_id
    								AND t.element_type = CONCAT('post_', wp_posts.post_type)  INNER JOIN wp_postmeta as METACF ON (wp_posts.ID = METACF.post_id)