Warning: Undefined array key "theme_name" in /var/www/aerokidsshopcom/app/functions/fn.init.php on line 683

Warning: Undefined array key "style_id" in /var/www/aerokidsshopcom/app/functions/fn.init.php on line 687

Warning: Undefined array key "theme_name" in /var/www/aerokidsshopcom/app/functions/fn.init.php on line 688
SELECT 
  lang.name, 
  IF(
    cscart_ult_language_values.value IS NULL, 
    lang.value, cscart_ult_language_values.value
  ) as value 
FROM 
  cscart_language_values lang 
  LEFT JOIN cscart_ult_language_values ON cscart_ult_language_values.name = lang.name 
  AND company_id = 1 
  AND cscart_ult_language_values.lang_code = lang.lang_code 
WHERE 
  lang.lang_code = 'en' 
  AND lang.name IN (
    'geo_maps.google_maps_cookie_title', 
    'geo_maps.google_maps_cookie_description', 
    'geo_maps.yandex_maps_cookie_title', 
    'geo_maps.yandex_maps_cookie_description', 
    'geo_maps.google_maps_cookie_title', 
    'geo_maps.google_maps_cookie_description', 
    'geo_maps.yandex_maps_cookie_title', 
    'geo_maps.yandex_maps_cookie_description'
  )

Query time 0.00728

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "5.36"
    },
    "nested_loop": [
      {
        "table": {
          "table_name": "lang",
          "access_type": "range",
          "possible_keys": [
            "PRIMARY"
          ],
          "key": "PRIMARY",
          "used_key_parts": [
            "lang_code",
            "name"
          ],
          "key_length": "392",
          "rows_examined_per_scan": 4,
          "rows_produced_per_join": 4,
          "filtered": "100.00",
          "cost_info": {
            "read_cost": "4.31",
            "eval_cost": "0.40",
            "prefix_cost": "4.71",
            "data_read_per_join": "1K"
          },
          "used_columns": [
            "lang_code",
            "name",
            "value"
          ],
          "attached_condition": "((`aerokidsshop`.`lang`.`lang_code` = 'en') and (`aerokidsshop`.`lang`.`name` in ('geo_maps.google_maps_cookie_title','geo_maps.google_maps_cookie_description','geo_maps.yandex_maps_cookie_title','geo_maps.yandex_maps_cookie_description','geo_maps.google_maps_cookie_title','geo_maps.google_maps_cookie_description','geo_maps.yandex_maps_cookie_title','geo_maps.yandex_maps_cookie_description')))"
        }
      },
      {
        "table": {
          "table_name": "cscart_ult_language_values",
          "access_type": "ALL",
          "possible_keys": [
            "PRIMARY"
          ],
          "rows_examined_per_scan": 1,
          "rows_produced_per_join": 4,
          "filtered": "100.00",
          "using_join_buffer": "hash join",
          "cost_info": {
            "read_cost": "0.25",
            "eval_cost": "0.40",
            "prefix_cost": "5.36",
            "data_read_per_join": "1K"
          },
          "used_columns": [
            "lang_code",
            "name",
            "value",
            "company_id"
          ],
          "attached_condition": "<if>(is_not_null_compl(cscart_ult_language_values), ((`aerokidsshop`.`cscart_ult_language_values`.`lang_code` = `aerokidsshop`.`lang`.`lang_code`) and (`aerokidsshop`.`cscart_ult_language_values`.`company_id` = 1) and (`aerokidsshop`.`cscart_ult_language_values`.`name` = `aerokidsshop`.`lang`.`name`)), true)"
        }
      }
    ]
  }
}

Result

name value
geo_maps.google_maps_cookie_description Google Maps is a service that allows us to show the maps and various locations on those maps, or automatically determine your location. Here is <a href="https://policies.google.com/privacy" target="_blank">Google privacy policy;</a> we also recommend Google's concise and comprehensive <a href="https://support.google.com/maps/answer/10400210" target="_blank">note on privacy</a>.
geo_maps.google_maps_cookie_title Google Maps
geo_maps.yandex_maps_cookie_description Yandex Maps is a service that allows us to show the maps and various locations on those maps, or automatically determine your location. Here is <a href="https://yandex.com/legal/confidential/" target="_blank">Yandex privacy policy</a>.
geo_maps.yandex_maps_cookie_title Yandex Maps