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 (
    'stripe.online_payment', 'stripe.stripe_cookie_title', 
    'stripe.stripe_cookie_description', 
    'stripe.online_payment', 'stripe.stripe_cookie_title', 
    'stripe.stripe_cookie_description'
  )

Query time 0.00151

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "3.98"
    },
    "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": 3,
          "rows_produced_per_join": 3,
          "filtered": "100.00",
          "cost_info": {
            "read_cost": "3.12",
            "eval_cost": "0.30",
            "prefix_cost": "3.42",
            "data_read_per_join": "1K"
          },
          "used_columns": [
            "lang_code",
            "name",
            "value"
          ],
          "attached_condition": "((`aerokidsshop`.`lang`.`lang_code` = 'en') and (`aerokidsshop`.`lang`.`name` in ('stripe.online_payment','stripe.stripe_cookie_title','stripe.stripe_cookie_description','stripe.online_payment','stripe.stripe_cookie_title','stripe.stripe_cookie_description')))"
        }
      },
      {
        "table": {
          "table_name": "cscart_ult_language_values",
          "access_type": "ALL",
          "possible_keys": [
            "PRIMARY"
          ],
          "rows_examined_per_scan": 1,
          "rows_produced_per_join": 3,
          "filtered": "100.00",
          "using_join_buffer": "hash join",
          "cost_info": {
            "read_cost": "0.25",
            "eval_cost": "0.30",
            "prefix_cost": "3.98",
            "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
stripe.online_payment Online payment
stripe.stripe_cookie_description Stripe is a payment provider. It allows us to accept payments, if you choose a payment method powered by Stripe. Here is <a href="https://stripe.com/privacy" target="_blank">Stripe privacy policy</a>.
stripe.stripe_cookie_title Stripe