Query time 0.00161
JSON explain
{
"query_block": {
"select_id": 1,
"nested_loop": [
{
"read_sorted_file": {
"filesort": {
"sort_key": "cscart_product_reviews.product_review_timestamp desc",
"table": {
"table_name": "cscart_product_reviews",
"access_type": "ref",
"possible_keys": ["idx_product_id"],
"key": "idx_product_id",
"key_length": "3",
"used_key_parts": ["product_id"],
"ref": ["const"],
"rows": 4,
"filtered": 100,
"attached_condition": "cscart_product_reviews.product_id <=> 5288 and cscart_product_reviews.`status` = 'A'"
}
}
}
},
{
"table": {
"table_name": "cscart_users",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY"],
"key": "PRIMARY",
"key_length": "3",
"used_key_parts": ["user_id"],
"ref": ["dev_db.cscart_product_reviews.reply_user_id"],
"rows": 1,
"filtered": 100
}
},
{
"table": {
"table_name": "cscart_companies",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY"],
"key": "PRIMARY",
"key_length": "4",
"used_key_parts": ["company_id"],
"ref": ["dev_db.cscart_users.company_id"],
"rows": 1,
"filtered": 100,
"attached_condition": "trigcond(trigcond(cscart_users.company_id is not null))"
}
},
{
"table": {
"table_name": "cscart_country_descriptions",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY"],
"key": "PRIMARY",
"key_length": "12",
"used_key_parts": ["code", "lang_code"],
"ref": ["dev_db.cscart_product_reviews.country_code", "const"],
"rows": 1,
"filtered": 100,
"attached_condition": "trigcond(cscart_country_descriptions.lang_code = 'en')"
}
}
]
}
}
Result
product_review_id |
product_id |
user_id |
name |
advantages |
disadvantages |
quick_comment |
comment |
rating_value |
ip_address |
is_buyer |
product_review_timestamp |
country_code |
city |
reply_user_id |
reply |
reply_timestamp |
helpfulness |
status |
storefront_id |
images_count |
vote_up |
vote_down |
reply_company_id |
reply_company |
country |
21654 |
5288 |
7325 |
Vũ Vũ |
|
|
Tuyệt vời |
Trà là món quà ý nghĩa dành tặng người thân, bạn bè. Mình hay mua trà biếu bố mẹ, ông bà, ai cũng thích |
5 |
abf4b968 |
N |
1710152163 |
VN |
79 |
0 |
|
0 |
0 |
A |
1 |
0 |
0 |
0 |
|
|
Viet Nam |
21652 |
5288 |
7325 |
Nguyễn Ngọc Mai |
|
|
Tuyệt vời |
Trà này là thức uống ngon, bổ, rẻ, phù hợp với mọi lứa tuổi. Vị trà tự nhiên, an toàn cho sức khỏe |
5 |
abf4b968 |
N |
1710152151 |
VN |
79 |
0 |
|
0 |
0 |
A |
1 |
0 |
0 |
0 |
|
|
Viet Nam |
21650 |
5288 |
7325 |
Xuân Xanh |
|
|
Tuyệt vời |
Uống trà này mỗi ngày giúp mình thanh lọc cơ thể, đẹp da, giữ dáng. Vị trà tự nhiên, an toàn cho sức khỏe. |
5 |
abf4b968 |
N |
1710152130 |
VN |
79 |
0 |
|
0 |
0 |
A |
1 |
0 |
0 |
0 |
|
|
Viet Nam |
21645 |
5288 |
7325 |
Quang Anh |
|
|
Tuyệt vời |
Trà dịu nhẹ, mùi thơm dễ uống |
5 |
abf4b968 |
N |
1710152099 |
VN |
79 |
0 |
|
0 |
0 |
A |
1 |
0 |
0 |
0 |
|
|
Viet Nam |
21643 |
5288 |
7325 |
Duyên Vũ |
|
|
Tuyệt vời |
Trà ngon đỉnh á! Vị thanh mát, ngọt dịu, uống là ghiền, thơm ơi là thơm. Mua về pha trà sữa tại nhà vừa ngon vừa rẻ, hợp túi tiền học sinh. Hoặc mấy lúc stress thì uống cũng thư giãn lắm, đầu óc nhẹ nhàng hẳn, nên thử nha mọi người ơi |
5 |
abf4b968 |
N |
1710152081 |
VN |
79 |
0 |
|
0 |
0 |
A |
1 |
0 |
0 |
0 |
|
|
Viet Nam |