20.44 ms (39.69%)
|
1 |
SELECT DISTINCT s0_.id AS id_0, p1_.name AS name_1 FROM supplier_has_product s0_ LEFT JOIN product p1_ ON s0_.product_id = p1_.id LEFT JOIN supplier s2_ ON s0_.supplier_id = s2_.id LEFT JOIN product_category p3_ ON p1_.category_id = p3_.id LEFT JOIN hotel_exclude_product h4_ ON p1_.id = h4_.product_id WHERE (p1_.is_active IN (?, ?) AND s2_.is_active = ? AND s0_.is_active = ? AND s0_.price > 0) AND ((h4_.hotel_id = ? OR h4_.hotel_id IS NULL)) AND s2_.id IN (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) AND s2_.id NOT IN (?, ?) AND ((p1_.name LIKE ? OR p1_.id = ? OR p3_.name = ? OR s0_.supplier_code = ? OR p1_.manufacturer LIKE ?)) AND s2_.id = ? ORDER BY p1_.name ASC LIMIT 50
Parameters: [
1
2
1
1
24
4
37
32
30
31
27
25
24
23
22
18
17
16
38
39
35
36
48
44
50
26
61
74
47
23
17
"%RYŻ%"
"RYŻ"
"RYŻ"
"RYŻ"
"RYŻ"
"74"
]
SELECT DISTINCT s0_.id AS id_0, p1_.name AS name_1 FROM supplier_has_product s0_ LEFT JOIN product p1_ ON s0_.product_id = p1_.id LEFT JOIN supplier s2_ ON s0_.supplier_id = s2_.id LEFT JOIN product_category p3_ ON p1_.category_id = p3_.id LEFT JOIN hotel_exclude_product h4_ ON p1_.id = h4_.product_id WHERE (p1_.is_active IN (1, 2) AND s2_.is_active = 1 AND s0_.is_active = 1 AND s0_.price > 0) AND ((h4_.hotel_id = 24 OR h4_.hotel_id IS NULL)) AND s2_.id IN (4, 37, 32, 30, 31, 27, 25, 24, 23, 22, 18, 17, 16, 38, 39, 35, 36, 48, 44, 50, 26, 61, 74, 47) AND s2_.id NOT IN (23, 17) AND ((p1_.name LIKE '%RYÅ»%' OR p1_.id = 'RYÅ»' OR p3_.name = 'RYÅ»' OR s0_.supplier_code = 'RYÅ»' OR p1_.manufacturer LIKE 'RYÅ»')) AND s2_.id = '74' ORDER BY p1_.name ASC LIMIT 50;
|
20.41 ms (39.64%)
|
1 |
SELECT COUNT(DISTINCT s0_.id) AS sclr_0 FROM supplier_has_product s0_ LEFT JOIN product p1_ ON s0_.product_id = p1_.id LEFT JOIN supplier s2_ ON s0_.supplier_id = s2_.id LEFT JOIN product_category p3_ ON p1_.category_id = p3_.id LEFT JOIN hotel_exclude_product h4_ ON p1_.id = h4_.product_id WHERE (p1_.is_active IN (?, ?) AND s2_.is_active = ? AND s0_.is_active = ? AND s0_.price > 0) AND ((h4_.hotel_id = ? OR h4_.hotel_id IS NULL)) AND s2_.id IN (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) AND s2_.id NOT IN (?, ?) AND ((p1_.name LIKE ? OR p1_.id = ? OR p3_.name = ? OR s0_.supplier_code = ? OR p1_.manufacturer LIKE ?)) AND s2_.id = ?
Parameters: [
1
2
1
1
24
4
37
32
30
31
27
25
24
23
22
18
17
16
38
39
35
36
48
44
50
26
61
74
47
23
17
"%RYŻ%"
"RYŻ"
"RYŻ"
"RYŻ"
"RYŻ"
"74"
]
SELECT COUNT(DISTINCT s0_.id) AS sclr_0 FROM supplier_has_product s0_ LEFT JOIN product p1_ ON s0_.product_id = p1_.id LEFT JOIN supplier s2_ ON s0_.supplier_id = s2_.id LEFT JOIN product_category p3_ ON p1_.category_id = p3_.id LEFT JOIN hotel_exclude_product h4_ ON p1_.id = h4_.product_id WHERE (p1_.is_active IN (1, 2) AND s2_.is_active = 1 AND s0_.is_active = 1 AND s0_.price > 0) AND ((h4_.hotel_id = 24 OR h4_.hotel_id IS NULL)) AND s2_.id IN (4, 37, 32, 30, 31, 27, 25, 24, 23, 22, 18, 17, 16, 38, 39, 35, 36, 48, 44, 50, 26, 61, 74, 47) AND s2_.id NOT IN (23, 17) AND ((p1_.name LIKE '%RYÅ»%' OR p1_.id = 'RYÅ»' OR p3_.name = 'RYÅ»' OR s0_.supplier_code = 'RYÅ»' OR p1_.manufacturer LIKE 'RYÅ»')) AND s2_.id = '74';
|
0.21 ms (0.41%)
|
1 |
SELECT s0_.id AS id_0, s0_.price AS price_1, s0_.supplier_code AS supplier_code_2, s0_.image AS image_3, s0_.last_price AS last_price_4, s0_.price_changed_at AS price_changed_at_5, s0_.price_last_at AS price_last_at_6, s0_.is_active AS is_active_7, s0_.extra_data AS extra_data_8, s0_.last_is_active AS last_is_active_9, s0_.supplier_id AS supplier_id_10, s0_.product_id AS product_id_11 FROM supplier_has_product s0_ LEFT JOIN product p1_ ON s0_.product_id = p1_.id LEFT JOIN supplier s2_ ON s0_.supplier_id = s2_.id LEFT JOIN product_category p3_ ON p1_.category_id = p3_.id LEFT JOIN hotel_exclude_product h4_ ON p1_.id = h4_.product_id WHERE (p1_.is_active IN (?, ?) AND s2_.is_active = ? AND s0_.is_active = ? AND s0_.price > 0) AND ((h4_.hotel_id = ? OR h4_.hotel_id IS NULL)) AND s2_.id IN (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) AND s2_.id NOT IN (?, ?) AND ((p1_.name LIKE ? OR p1_.id = ? OR p3_.name = ? OR s0_.supplier_code = ? OR p1_.manufacturer LIKE ?)) AND s2_.id = ? AND s0_.id IN (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) ORDER BY p1_.name ASC
Parameters: [
1
2
1
1
24
4
37
32
30
31
27
25
24
23
22
18
17
16
38
39
35
36
48
44
50
26
61
74
47
23
17
"%RYŻ%"
"RYŻ"
"RYŻ"
"RYŻ"
"RYŻ"
"74"
120787
120795
102969
102971
81618
123773
75214
75207
75202
75195
75189
75182
86343
75936
114124
78980
121222
82199
98758
98772
84284
131160
122150
131941
128510
108893
119078
101242
101235
105010
98730
105886
98751
98765
101228
98737
105017
95529
121989
78082
120587
134368
85436
97201
82535
82542
150161
74915
123793
106000
]
SELECT
s0_.id AS id_0,
s0_.price AS price_1,
s0_.supplier_code AS supplier_code_2,
s0_.image AS image_3,
s0_.last_price AS last_price_4,
s0_.price_changed_at AS price_changed_at_5,
s0_.price_last_at AS price_last_at_6,
s0_.is_active AS is_active_7,
s0_.extra_data AS extra_data_8,
s0_.last_is_active AS last_is_active_9,
s0_.supplier_id AS supplier_id_10,
s0_.product_id AS product_id_11
FROM
supplier_has_product s0_
LEFT JOIN product p1_ ON s0_.product_id = p1_.id
LEFT JOIN supplier s2_ ON s0_.supplier_id = s2_.id
LEFT JOIN product_category p3_ ON p1_.category_id = p3_.id
LEFT JOIN hotel_exclude_product h4_ ON p1_.id = h4_.product_id
WHERE
(
p1_.is_active IN (?, ?)
AND s2_.is_active = ?
AND s0_.is_active = ?
AND s0_.price > 0
)
AND (
(
h4_.hotel_id = ?
OR h4_.hotel_id IS NULL
)
)
AND s2_.id IN (
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?
)
AND s2_.id NOT IN (?, ?)
AND (
(
p1_.name LIKE ?
OR p1_.id = ?
OR p3_.name = ?
OR s0_.supplier_code = ?
OR p1_.manufacturer LIKE ?
)
)
AND s2_.id = ?
AND s0_.id IN (
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?
)
ORDER BY
p1_.name ASC
SELECT s0_.id AS id_0, s0_.price AS price_1, s0_.supplier_code AS supplier_code_2, s0_.image AS image_3, s0_.last_price AS last_price_4, s0_.price_changed_at AS price_changed_at_5, s0_.price_last_at AS price_last_at_6, s0_.is_active AS is_active_7, s0_.extra_data AS extra_data_8, s0_.last_is_active AS last_is_active_9, s0_.supplier_id AS supplier_id_10, s0_.product_id AS product_id_11 FROM supplier_has_product s0_ LEFT JOIN product p1_ ON s0_.product_id = p1_.id LEFT JOIN supplier s2_ ON s0_.supplier_id = s2_.id LEFT JOIN product_category p3_ ON p1_.category_id = p3_.id LEFT JOIN hotel_exclude_product h4_ ON p1_.id = h4_.product_id WHERE (p1_.is_active IN (1, 2) AND s2_.is_active = 1 AND s0_.is_active = 1 AND s0_.price > 0) AND ((h4_.hotel_id = 24 OR h4_.hotel_id IS NULL)) AND s2_.id IN (4, 37, 32, 30, 31, 27, 25, 24, 23, 22, 18, 17, 16, 38, 39, 35, 36, 48, 44, 50, 26, 61, 74, 47) AND s2_.id NOT IN (23, 17) AND ((p1_.name LIKE '%RYÅ»%' OR p1_.id = 'RYÅ»' OR p3_.name = 'RYÅ»' OR s0_.supplier_code = 'RYÅ»' OR p1_.manufacturer LIKE 'RYÅ»')) AND s2_.id = '74' AND s0_.id IN (120787, 120795, 102969, 102971, 81618, 123773, 75214, 75207, 75202, 75195, 75189, 75182, 86343, 75936, 114124, 78980, 121222, 82199, 98758, 98772, 84284, 131160, 122150, 131941, 128510, 108893, 119078, 101242, 101235, 105010, 98730, 105886, 98751, 98765, 101228, 98737, 105017, 95529, 121989, 78082, 120587, 134368, 85436, 97201, 82535, 82542, 150161, 74915, 123793, 106000) ORDER BY p1_.name ASC;
|
0.11 ms (0.22%)
|
1 |
SELECT t0.id AS id_1, t0.name AS name_2, t0.city AS city_3, t0.address AS address_4, t0.phone AS phone_5, t0.email AS email_6, t0.is_active AS is_active_7, t0.crated_at AS crated_at_8, t0.postcode AS postcode_9, t0.email_txt AS email_txt_10, t0.order_confirm_type AS order_confirm_type_11, t0.col_name AS col_name_12, t0.col_number AS col_number_13, t0.col_price AS col_price_14, t0.min_price AS min_price_15, t0.col_ean AS col_ean_16, t0.col_image AS col_image_17, t0.col_pieces AS col_pieces_18, t0.col_weight AS col_weight_19, t0.nip AS nip_20, t0.contact_name AS contact_name_21, t0.contact_surname AS contact_surname_22, t0.shortcut AS shortcut_23, t0.payment_term AS payment_term_24, t0.col_manufacture AS col_manufacture_25, t0.email_type AS email_type_26 FROM supplier t0 WHERE t0.id = ?
SELECT t0.id AS id_1, t0.name AS name_2, t0.city AS city_3, t0.address AS address_4, t0.phone AS phone_5, t0.email AS email_6, t0.is_active AS is_active_7, t0.crated_at AS crated_at_8, t0.postcode AS postcode_9, t0.email_txt AS email_txt_10, t0.order_confirm_type AS order_confirm_type_11, t0.col_name AS col_name_12, t0.col_number AS col_number_13, t0.col_price AS col_price_14, t0.min_price AS min_price_15, t0.col_ean AS col_ean_16, t0.col_image AS col_image_17, t0.col_pieces AS col_pieces_18, t0.col_weight AS col_weight_19, t0.nip AS nip_20, t0.contact_name AS contact_name_21, t0.contact_surname AS contact_surname_22, t0.shortcut AS shortcut_23, t0.payment_term AS payment_term_24, t0.col_manufacture AS col_manufacture_25, t0.email_type AS email_type_26 FROM supplier t0 WHERE t0.id = 74;
|