I have made some changes: SELECT wp_posts.ID FROM wp_posts INNER JOIN wp_postmeta ON wp_posts.ID = wp_postmeta.post_id INNER JOIN wp_icl_translations t ON wp_posts.ID = t.element_id WHERE 1=1 AND t.element_type = CONCAT(‘post_’, wp_posts.post_type) AND wp_postmeta.meta_key = ‘post_views_count’ AND wp_posts.post_type=”post” AND wp_posts.post_status=”publish” AND ( (t.language_code=”fr” AND wp_posts.post_type IN (‘post’,’page’,’attachment’,’grille’,’podcast’,’equipe’)) OR wp_posts.post_type NOT IN (‘post’,’page’,’attachment’,’grille’,’podcast’,’equipe’) ) GROUP BY wp_posts.ID … Read more