Query time 0.00963
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "9.05"
},
"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",
"idx_status"
],
"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": "14K"
},
"used_columns": [
"company_id",
"status",
"company",
"city",
"state",
"ag_hide_city"
]
}
},
{
"table": {
"table_name": "categories",
"access_type": "range",
"possible_keys": [
"PRIMARY",
"c_status",
"p_category_id"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id"
],
"key_length": "3",
"rows_examined_per_scan": 5,
"rows_produced_per_join": 0,
"filtered": "4.00",
"cost_info": {
"read_cost": "2.24",
"eval_cost": "0.02",
"prefix_cost": "2.26",
"data_read_per_join": "536"
},
"used_columns": [
"category_id",
"usergroup_ids",
"status",
"storefront_id"
],
"attached_condition": "((`goimagine`.`categories`.`category_id` in (7707,7762,8161,8577,9688)) and ((`goimagine`.`categories`.`usergroup_ids` = '') or (0 <> find_in_set(0,`goimagine`.`categories`.`usergroup_ids`)) or (0 <> find_in_set(1,`goimagine`.`categories`.`usergroup_ids`))) and (`goimagine`.`categories`.`status` in ('A','H')) and (`goimagine`.`categories`.`storefront_id` in (0,1)))"
}
},
{
"table": {
"table_name": "products_categories",
"access_type": "ref",
"possible_keys": [
"PRIMARY",
"pt"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id"
],
"key_length": "3",
"ref": [
"goimagine.categories.category_id"
],
"rows_examined_per_scan": 68,
"rows_produced_per_join": 13,
"filtered": "100.00",
"using_index": true,
"cost_info": {
"read_cost": "0.05",
"eval_cost": "1.36",
"prefix_cost": "3.68",
"data_read_per_join": "217"
},
"used_columns": [
"product_id",
"category_id"
]
}
},
{
"table": {
"table_name": "products",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"age_verification",
"status",
"idx_company_id",
"idx_usergroup_ids",
"idx_amount",
"index_products_on_deleted_at"
],
"key": "PRIMARY",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"goimagine.products_categories.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "5.00",
"cost_info": {
"read_cost": "3.41",
"eval_cost": "0.07",
"prefix_cost": "8.45",
"data_read_per_join": "2K"
},
"used_columns": [
"product_id",
"status",
"company_id",
"amount",
"usergroup_ids",
"tracking"
],
"attached_condition": "((`goimagine`.`products`.`company_id` = 3119) and ((`goimagine`.`products`.`amount` > 0) or (`goimagine`.`products`.`tracking` = 'D')) and ((`goimagine`.`products`.`usergroup_ids` = '') or (0 <> find_in_set(0,`goimagine`.`products`.`usergroup_ids`)) or (0 <> find_in_set(1,`goimagine`.`products`.`usergroup_ids`))) and (`goimagine`.`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": [
"goimagine.products_categories.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "25.00",
"cost_info": {
"read_cost": "0.18",
"eval_cost": "0.02",
"prefix_cost": "8.70",
"data_read_per_join": "4"
},
"used_columns": [
"id",
"product_id",
"lower_limit",
"usergroup_id"
],
"attached_condition": "((`goimagine`.`prices`.`lower_limit` = 1) and (`goimagine`.`prices`.`usergroup_id` in (0,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": "11",
"ref": [
"goimagine.products_categories.product_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.11",
"eval_cost": "0.02",
"prefix_cost": "8.83",
"data_read_per_join": "920"
},
"used_columns": [
"product_id",
"lang_code",
"product"
]
}
},
{
"table": {
"table_name": "inventory",
"access_type": "ref",
"possible_keys": [
"pc"
],
"key": "pc",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"goimagine.products_categories.product_id"
],
"rows_examined_per_scan": 3,
"rows_produced_per_join": 0,
"filtered": "100.00",
"using_index": true,
"cost_info": {
"read_cost": "0.05",
"eval_cost": "0.06",
"prefix_cost": "8.94",
"data_read_per_join": "585"
},
"used_columns": [
"product_id",
"combination_hash"
]
}
},
{
"table": {
"table_name": "popularity",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"total"
],
"key": "PRIMARY",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"goimagine.products_categories.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.04",
"eval_cost": "0.06",
"prefix_cost": "9.05",
"data_read_per_join": "19"
},
"used_columns": [
"product_id",
"total"
]
}
}
]
}
}
}
}
Result
| product_id |
product |
company_name |
company_city_hide |
company_city |
company_state |
| 133119 |
Fall Harvest Candle | Pure Soy Wax Candle | Holiday Candle | Fall Candles | Autumn Candle | Thanksgiving Candle | Winter Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 133181 |
Jasmine and Green Apple Scented Candle, Hand Poured 100% Soy Wax 8 Ounce Candle, Fruity Fresh Scented Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 132710 |
Pumpkin Soufflé Candle, Hand Poured 100% Soy Wax 8 Oz Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 136506 |
Jolly AF Christmas Candle, Funny Candle, Gag Gift for Friend, Handpoured Soy Wax Scented Candle, Christmas Candle, Funny Christmas Gift |
Tennessee Wicks |
N |
Lyles |
TN |
| 144342 |
Believe Sasquatch Bigfoot Christmas Candle, 8oz Handpoured Soy Wax Candle, Choose Your Scent |
Tennessee Wicks |
N |
Lyles |
TN |
| 133145 |
Halloween Candle, It's Boo Time, Choose Your Scent 8oz Soy Wax Candle, Autumn Décor, Fall Candle, Halloween Décor, Pumpkin Scent Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 132999 |
Personalized Birthday Candle | 8oz Soy Wax Candle Gift | Choose Scent and Add Personal Message |
Tennessee Wicks |
N |
Lyles |
TN |
| 133122 |
Hello Fall Candle | Fall Candle | 8oz Choose Your Scent | Soy Wax Candle | Autumn Themed Décor | Thanksgiving Themed | Thanksgiving Décor |
Tennessee Wicks |
N |
Lyles |
TN |
| 132714 |
Hello Sweater Weather Candle, 8oz Choose Your Scent Soy Wax Candle, Fall Themed Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 144442 |
Happy Holidays Christmas Gift Candle, Choose Your Scent 8oz Soy Wax Handpoured Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 133121 |
Apple Cinnamon Berry Candle | All Natural Soy Wax | Apple Cinnamon Scent | Fall Scented Candle | Relaxing Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 132652 |
Pumpkin Pecan Waffle Scented Candle Hand Poured 100% Soy Wax 8 Ounce Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 133127 |
Blueberry Cobbler Candle | Soy Wax Candle | Blueberry Pie Candle | Fruity Scent Candle | Handpoured 8Oz Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 136514 |
Dead Inside But Still Merry Christmas Candle, Funny Candle, Gag Gift for Friend, Handpoured Soy Wax Scented Candle, Funny Christmas Gift |
Tennessee Wicks |
N |
Lyles |
TN |
| 133132 |
Hot Apple Pie Candle, Apple Pie Soy Candle, Halloween Candle, Fall Candle, Thanksgiving Candle, Autumn Decor, Fall Fragrance Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 133143 |
Black Cats Only Candle, Halloween Candle, Choose Your Scent 8oz Soy Wax Candle, Fall Candle, Halloween Décor, Pumpkin Scent Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 133136 |
Oh My Pumpkin Pie!, Pumpkin Soy Candle, Halloween Candle, Fall Candle, Pumpkin Spice Candle, Thanksgiving Candle, Autumn Decor |
Tennessee Wicks |
N |
Lyles |
TN |
| 133172 |
Apple Pumpkin Butter Candle, Hand Poured 100% Soy Wax 8 Ounce Candle, Fall Scented Candle, Thanksgiving Candle, Holiday Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 133182 |
Sage Leaf Scented Candle, Hand Poured 100% Soy Wax 8 Ounce Candle, Cleansing Candle, Ritual Candle, Positive Energy Candle, Good Vibes Scent |
Tennessee Wicks |
N |
Lyles |
TN |
| 133139 |
Halloween Candle, Trick or Treat Candle, Choose Your Scent 8oz Soy Wax Candle, Fall Candle, Halloween Décor, Pumpkin Scent Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 140843 |
Sorry For All The F-bombs Christmas Candle, 8oz Handpoured Soy Wax Candle, Choose Your Scent |
Tennessee Wicks |
N |
Lyles |
TN |
| 133168 |
English Ivy Scented Candle, Handpoured 8oz Soy Wax Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 133123 |
Red Apple Candle | All Natural Soy Wax | Red Apple Scented Candle | Relaxing Candle | New Home Gift | Toxin Free Candle |
Tennessee Wicks |
N |
Lyles |
TN |
| 133180 |
Egyptian Amber Scented Candle, Hand Poured 100% Soy Wax 8 Ounce Candle, Exotic Relaxing Sensual Candle |
Tennessee Wicks |
N |
Lyles |
TN |