Query time 0.05675
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "3092.60"
},
"ordering_operation": {
"using_filesort": true,
"grouping_operation": {
"using_temporary_table": true,
"using_filesort": false,
"nested_loop": [
{
"table": {
"table_name": "companies",
"access_type": "const",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"company_id"
],
"key_length": "4",
"ref": [
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 1,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.00",
"eval_cost": "0.10",
"prefix_cost": "0.00",
"data_read_per_join": "15K"
},
"used_columns": [
"company_id",
"status",
"company",
"discreet_shipping"
]
}
},
{
"table": {
"table_name": "products",
"access_type": "ref",
"possible_keys": [
"PRIMARY",
"status",
"idx_parent_product_id"
],
"key": "idx_parent_product_id",
"used_key_parts": [
"parent_product_id"
],
"key_length": "4",
"ref": [
"const"
],
"rows_examined_per_scan": 15524,
"rows_produced_per_join": 305,
"filtered": "1.97",
"cost_info": {
"read_cost": "884.27",
"eval_cost": "30.53",
"prefix_cost": "2436.68",
"data_read_per_join": "1M"
},
"used_columns": [
"product_id",
"product_type",
"status",
"company_id",
"amount",
"usergroup_ids",
"parent_product_id",
"variation_sku"
],
"attached_condition": "((`cscartdb`.`products`.`company_id` = 99) and (`cscartdb`.`products`.`amount` > 0) and ((`cscartdb`.`products`.`usergroup_ids` = '') or (0 <> find_in_set(0,`cscartdb`.`products`.`usergroup_ids`)) or (0 <> find_in_set(1,`cscartdb`.`products`.`usergroup_ids`))) and (`cscartdb`.`products`.`status` = 'A'))"
}
},
{
"table": {
"table_name": "prices",
"access_type": "ref",
"possible_keys": [
"usergroup",
"product_id",
"lower_limit",
"usergroup_id"
],
"key": "product_id",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"cscartdb.products.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 305,
"filtered": "99.99",
"cost_info": {
"read_cost": "76.33",
"eval_cost": "30.53",
"prefix_cost": "2543.53",
"data_read_per_join": "7K"
},
"used_columns": [
"product_id",
"lower_limit",
"usergroup_id"
],
"attached_condition": "((`cscartdb`.`prices`.`lower_limit` = 1) and (`cscartdb`.`prices`.`usergroup_id` in (0,0,1)))"
}
},
{
"table": {
"table_name": "popularity",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"total"
],
"key": "PRIMARY",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"cscartdb.products.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 305,
"filtered": "100.00",
"cost_info": {
"read_cost": "76.32",
"eval_cost": "30.53",
"prefix_cost": "2650.38",
"data_read_per_join": "9K"
},
"used_columns": [
"product_id",
"total"
]
}
},
{
"table": {
"table_name": "products_categories",
"access_type": "ref",
"possible_keys": [
"PRIMARY",
"pt"
],
"key": "pt",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"cscartdb.products.product_id"
],
"rows_examined_per_scan": 2,
"rows_produced_per_join": 610,
"filtered": "100.00",
"cost_info": {
"read_cost": "152.64",
"eval_cost": "61.06",
"prefix_cost": "2864.08",
"data_read_per_join": "9K"
},
"used_columns": [
"product_id",
"category_id"
]
}
},
{
"table": {
"table_name": "cscart_categories",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"c_status",
"p_category_id"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id"
],
"key_length": "3",
"ref": [
"cscartdb.products_categories.category_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 30,
"filtered": "5.00",
"cost_info": {
"read_cost": "152.64",
"eval_cost": "3.05",
"prefix_cost": "3077.77",
"data_read_per_join": "102K"
},
"used_columns": [
"category_id",
"storefront_id",
"usergroup_ids",
"status"
],
"attached_condition": "(((`cscartdb`.`cscart_categories`.`usergroup_ids` = '') or (0 <> find_in_set(0,`cscartdb`.`cscart_categories`.`usergroup_ids`)) or (0 <> find_in_set(1,`cscartdb`.`cscart_categories`.`usergroup_ids`))) and (`cscartdb`.`cscart_categories`.`status` in ('A','H')) and (`cscartdb`.`cscart_categories`.`storefront_id` in (0,1)))"
}
},
{
"table": {
"table_name": "descr1",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"product_id"
],
"key": "PRIMARY",
"used_key_parts": [
"product_id",
"lang_code"
],
"key_length": "9",
"ref": [
"cscartdb.products.product_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 30,
"filtered": "100.00",
"cost_info": {
"read_cost": "11.78",
"eval_cost": "3.05",
"prefix_cost": "3092.60",
"data_read_per_join": "116K"
},
"used_columns": [
"product_id",
"lang_code",
"product"
]
}
}
]
}
}
}
}
Result
product_id |
product |
company_name |
product_type |
parent_product_id |
variation_sku |
company_discreet_shipping |
60403 |
Leather Open Mouth Bondage Hood |
Restricted Senses |
P |
0 |
f1763353-c093-4d6c-9f2e-88f43f3e530e |
Y |
60371 |
Leather Bondage Hood |
Restricted Senses |
P |
0 |
63dab98a-d32f-46c1-a762-03ca45cbda82 |
Y |
60401 |
Leather Open Airway Bondage Hood |
Restricted Senses |
P |
0 |
04c0c5fa-121d-4643-b356-182267999be4 |
Y |
60362 |
Leather Gwendoline Bondage Hood |
Restricted Senses |
P |
0 |
85acbb06-d431-414d-9e5a-a97cdf219057 |
Y |
60402 |
Leather Open Eye Hole Bondage Hood |
Restricted Senses |
P |
0 |
d0dad17f-31a3-4c0a-96ca-5f7a93960c64 |
Y |
60357 |
Leather Bondage Armbinder |
Restricted Senses |
P |
0 |
fc73f1f5-036a-4977-91a4-2e75db708d0c |
Y |
60375 |
Leather Bondage Curved Blindfold with Buckle |
Restricted Senses |
P |
0 |
d30ce803-ed0f-45bf-8796-5d791dde3847 |
Y |
60376 |
Leather Bondage Face Cover Blindfold |
Restricted Senses |
P |
0 |
6100b4f4-1d35-4093-9022-daf70e7d7759 |
Y |
60358 |
Leather Bondage Armbinder - Zipper |
Restricted Senses |
P |
0 |
2cf98372-1b4e-4434-a985-8ac06d217004 |
Y |
60373 |
Leather Bondage Blindfold with Buckle |
Restricted Senses |
P |
0 |
a157d399-a5de-4ceb-8b10-3f321017d29b |
Y |
60377 |
Leather Bondage Facehugger Ball Gag |
Restricted Senses |
P |
0 |
80744d1d-04b4-4bfc-819b-5244e2377288 |
Y |
60383 |
Leather Bondage Mittens |
Restricted Senses |
P |
0 |
d9ca9f88-adcf-4fbb-ab57-db5b6f0d20dd |
Y |
60359 |
Leather Bondage Gwendoline Armbinder |
Restricted Senses |
P |
0 |
814bcd02-221a-4d75-affb-c2f522a9476f |
Y |
60392 |
Leather Chin Strap Bondage Ball Gag |
Restricted Senses |
P |
0 |
55459ef8-2c11-4d09-9cd7-047a6433dca9 |
Y |
60393 |
Leather Simple Single Strap Bondage Ball Gag |
Restricted Senses |
P |
0 |
79bb53b7-759a-4739-b60a-f0b64dfc806b |
Y |
60381 |
Leather Bondage Heavy Harness Gag |
Restricted Senses |
P |
0 |
411074ff-b000-4138-99ad-e5873edcf21f |
Y |
60385 |
Leather Bondage Panel Gag |
Restricted Senses |
P |
0 |
70a0c0f0-9536-4b6f-9020-3a808b5dbc33 |
Y |
60394 |
Leather Single Strap Bondage Ball Gag |
Restricted Senses |
P |
0 |
ab727167-5295-4a93-a303-5f3c5252652f |
Y |
60386 |
Leather Bondage Simple Style Harness Gag |
Restricted Senses |
P |
0 |
c60b67ad-fb50-4cdb-aa70-d3ec1e6a8ce5 |
Y |
60391 |
Leather Simple Chin Strap Bondage Ball Gag |
Restricted Senses |
P |
0 |
2753a5dd-efa8-4a64-8cdd-5bb77d92974c |
Y |
60408 |
Tear Drop Leather Bondage Collar & Leash Set |
Restricted Senses |
P |
0 |
|
Y |
60407 |
Tear Drop Leather Bondage Collar |
Restricted Senses |
P |
0 |
|
Y |
60384 |
Leather Bondage O-Ring Collar |
Restricted Senses |
P |
0 |
|
Y |
60397 |
Locking Post Arms to Collar Bondage Detention Restraint System |
Restricted Senses |
P |
0 |
|
Y |