SELECT 
  cscart_dosiin_posts.*, 
  cscart_dosiin_post_descriptions.*, 
  cscart_seo_names.name as seo_name, 
  cscart_seo_names.path as seo_path 
FROM 
  cscart_dosiin_posts 
  LEFT JOIN cscart_dosiin_post_categories ON cscart_dosiin_post_categories.post_id = cscart_dosiin_posts.post_id 
  LEFT JOIN cscart_dosiin_categories ON cscart_dosiin_categories.category_id = cscart_dosiin_post_categories.category_id 
  LEFT JOIN cscart_dosiin_post_descriptions ON cscart_dosiin_posts.post_id = cscart_dosiin_post_descriptions.post_id 
  AND cscart_dosiin_post_descriptions.lang_code = 'en' 
  LEFT JOIN cscart_seo_names ON cscart_seo_names.object_id = cscart_dosiin_posts.post_id 
  AND cscart_seo_names.type = 'b' 
  AND cscart_seo_names.dispatch = '' 
  AND cscart_seo_names.lang_code = 'en' 
WHERE 
  cscart_dosiin_posts.post_id = 523 
  AND (
    cscart_dosiin_categories.usergroup_ids = '' 
    OR FIND_IN_SET(
      0, cscart_dosiin_categories.usergroup_ids
    ) 
    OR FIND_IN_SET(
      1, cscart_dosiin_categories.usergroup_ids
    )
  ) 
  AND (
    cscart_dosiin_posts.usergroup_ids = '' 
    OR FIND_IN_SET(
      0, cscart_dosiin_posts.usergroup_ids
    ) 
    OR FIND_IN_SET(
      1, cscart_dosiin_posts.usergroup_ids
    )
  ) 
  AND cscart_dosiin_categories.status IN ('A', 'H') 
  AND cscart_dosiin_posts.status IN ('A', 'H')

Query time 0.01396

JSON explain

{
  "query_block": {
    "select_id": 1,
    "nested_loop": [
      {
        "table": {
          "table_name": "cscart_dosiin_posts",
          "access_type": "const",
          "possible_keys": ["PRIMARY", "status"],
          "key": "PRIMARY",
          "key_length": "3",
          "used_key_parts": ["post_id"],
          "ref": ["const"],
          "rows": 1,
          "filtered": 100
        }
      },
      {
        "table": {
          "table_name": "cscart_dosiin_post_descriptions",
          "access_type": "const",
          "possible_keys": ["PRIMARY"],
          "key": "PRIMARY",
          "key_length": "9",
          "used_key_parts": ["post_id", "lang_code"],
          "ref": ["const", "const"],
          "rows": 1,
          "filtered": 100
        }
      },
      {
        "table": {
          "table_name": "cscart_dosiin_post_categories",
          "access_type": "ref",
          "possible_keys": ["PRIMARY"],
          "key": "PRIMARY",
          "key_length": "3",
          "used_key_parts": ["post_id"],
          "ref": ["const"],
          "rows": 1,
          "filtered": 100,
          "using_index": true
        }
      },
      {
        "table": {
          "table_name": "cscart_dosiin_categories",
          "access_type": "eq_ref",
          "possible_keys": ["PRIMARY"],
          "key": "PRIMARY",
          "key_length": "3",
          "used_key_parts": ["category_id"],
          "ref": ["dev_db.cscart_dosiin_post_categories.category_id"],
          "rows": 1,
          "filtered": 100,
          "attached_condition": "(cscart_dosiin_categories.usergroup_ids = '' or find_in_set(0,cscart_dosiin_categories.usergroup_ids) or find_in_set(1,cscart_dosiin_categories.usergroup_ids)) and cscart_dosiin_categories.`status` in ('A','H')"
        }
      },
      {
        "table": {
          "table_name": "cscart_seo_names",
          "access_type": "ref",
          "possible_keys": ["PRIMARY", "dispatch"],
          "key": "PRIMARY",
          "key_length": "206",
          "used_key_parts": ["object_id", "type", "dispatch", "lang_code"],
          "ref": ["const", "const", "const", "const"],
          "rows": 1,
          "filtered": 100,
          "attached_condition": "trigcond(cscart_seo_names.`type` = 'b' and cscart_seo_names.dispatch = '' and cscart_seo_names.lang_code = 'en')"
        }
      }
    ]
  }
}

Result

post_id date timestamp separate status localization image_id company_id discussion_type author is_sent sent_timestamp featured usergroup_ids use_avail_period avail_from_timestamp avail_till_timestamp type total_view vote_up name short_description description lang_code page_title post_h2 post_h3 meta_description meta_keywords seo_name seo_path
523 1726038180 1726038180 N A 0 519 D Người Kể Chuyện N 0 N 0 N 0 0 R 111 76 Exciting Buy 1 Get 1 Offers in September on Chus.vn Discover the exciting September deals on Chus.vn: Buy 1 Get 1 on handcrafted products and meaningful gifts! Don’t miss the chance to grab a special item at an amazing price. <p>This September, Chus.vn brings you fantastic Buy 1 Get 1 offers as follows:</p> <h2><span style="font-weight: 400;">1. Buy 1 </span><span style="font-weight: 400;">Coffee Combo </span><span style="font-weight: 400;">Get 1 Coffee Box at Miss Ede </span></h2> <p>To celebrate the launch of the Sacred Islands Gift Box, when you purchase any Miss Ede Coffee Combo from now until the end of September 2024, you’ll receive an additional random coffee box from the set.</p> <p><span style="font-weight: 400;"><img src="https://static.chus.vn/images/thumbnails/850/637/product_mood_image/277/vn-11134207-7r98o-lzbfvjlo9601988.jpg" alt="cà phê mua 1 tặng 1 trên chus" width="850" height="637" /></span></p> <p style="text-align: center;"><em>The combos include: Trường Sa, Hoàng Sa, Là Của, and Việt Nam</em></p> <p>Miss Ede coffee combos not only deliver an exceptional taste experience but also allow you to spread love for your homeland and its islands. <span style="color: #ff0000;"><a style="color: #ff0000;" href="https://chus.vn/specialty-drip-coffee-combo-sacred-sovereignty-of-the-sea-and-islands/" target="_blank" rel="noopener"><strong>CLICK TO BUY NOW!</strong></a></span></p> <p style="padding-left: 30px; text-align: center;"><span style="font-size: 14pt;"><strong>About Miss Ede on CHUS.VN<br /></strong></span></p> <p>Founded in 2019 in Buôn Ma Thuột, Miss Ede aims to promote cultural beauty and support the Êđê community. It’s a pioneering brand in the Central Highlands, offering premium coffee and chocolate products from Vietnam. The image of an Êđê girl in a traditional gấm dress symbolizes the connection between culture and the high-quality products that Miss Ede provides.</p> <h2><span style="font-weight: 400;">2. Buy Agarwood Bracelet, Get a Free Charm at Tinh Agarwood</span></h2> <p>Throughout September, when you purchase any agarwood bracelet from Tinh Agarwood, you’ll receive a free feng shui silver charm. Choose from the following charm designs:</p> <ul> <li>Pixiu</li> <li>Lotus</li> <li>Buddha</li> <li>Geometric shapes</li> </ul> <p>Feng shui charms not only enhance the beauty of the agarwood bracelet but also bring good luck and positive energy to the wearer. <span style="color: #ff0000;"><a style="color: #ff0000;" href="https://chus.vn/tinh-agarwood-en/" target="_blank" rel="noopener"><strong>CLICK TO BUY NOW</strong></a></span></p> <p><span style="font-weight: 400;"><img src="https://chus.vn/images/detailed/204/1647352745_10051-03-f1_w767_h1105.jpg" alt="mua vòng tặng charm, mua 1 tặng 1" width="767" height="767" /></span></p> <p style="text-align: center;"><em><span style="font-weight: 400;">A Tinh Agarwood Bracelet</span></em></p> <p style="padding-left: 30px; text-align: center;"><span style="font-size: 14pt;"><strong>About Tinh Agarwood on CHUS.VN<br /></strong></span></p> <p>Tinh Agarwood was founded by Mr. Nghĩa, who has over 10 years of experience with agarwood. Agarwood is a precious wood formed over decades to centuries in nature, known for its rich fragrance and spiritual connection. Mr. Nghĩa created Tinh Agarwood with a passion for offering relaxation and positive energy through high-quality agarwood products, deeply connected to nature and daily life.<br /><br /></p> en Exciting Buy 1 Get 1 Offers in September on Chus.vn Discover the exciting September deals on Chus.vn: Buy 1 Get 1 on handcrafted products and meaningful gifts! Don’t miss the chance to grab a special item at an amazing price. hương, trầm, agarwood, tinh, miss, mang, được, tặng exciting-buy-1-get-1-offers-in-september-on-chus.vn 6