89.29 ms (76.76%)
|
1 |
SELECT phc.post_id, phc.category_id, c.slug, IFNULL(`r`.`name`, `f`.`name`) as `name` FROM post_has_category phc INNER JOIN category c ON phc.category_id = c.category_id AND c.enabled = 1 LEFT JOIN category_translation f ON c.category_id = f.category_id AND f.lang_id=? LEFT JOIN category_translation r ON `c`.`category_id` = `r`.`category_id` AND `r`.`lang_id`=? WHERE phc.post_id IN (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Parameters: [
1
2
414779
425214
425959
429899
439514
442612
447031
450901
450990
453394
453402
455117
455151
455479
455505
455719
458419
464566
476586
485276
492799
502598
504757
509415
515063
518597
518599
519346
520672
523358
524029
525337
528022
529392
529409
556577
558338
559682
561458
562061
562531
564162
574413
579707
582269
589634
589683
591197
599482
602092
605117
607694
622668
625556
682234
726487
726543
726553
]
SELECT
phc.post_id,
phc.category_id,
c.slug,
IFNULL(`r`.`name`, `f`.`name`) as `name`
FROM
post_has_category phc
INNER JOIN category c ON phc.category_id = c.category_id
AND c.enabled = 1
LEFT JOIN category_translation f ON c.category_id = f.category_id
AND f.lang_id = ?
LEFT JOIN category_translation r ON `c`.`category_id` = `r`.`category_id`
AND `r`.`lang_id` = ?
WHERE
phc.post_id IN (
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?
)
SELECT phc.post_id, phc.category_id, c.slug, IFNULL(`r`.`name`, `f`.`name`) as `name` FROM post_has_category phc INNER JOIN category c ON phc.category_id = c.category_id AND c.enabled = 1 LEFT JOIN category_translation f ON c.category_id = f.category_id AND f.lang_id=1 LEFT JOIN category_translation r ON `c`.`category_id` = `r`.`category_id` AND `r`.`lang_id`=2 WHERE phc.post_id IN (414779, 425214, 425959, 429899, 439514, 442612, 447031, 450901, 450990, 453394, 453402, 455117, 455151, 455479, 455505, 455719, 458419, 464566, 476586, 485276, 492799, 502598, 504757, 509415, 515063, 518597, 518599, 519346, 520672, 523358, 524029, 525337, 528022, 529392, 529409, 556577, 558338, 559682, 561458, 562061, 562531, 564162, 574413, 579707, 582269, 589634, 589683, 591197, 599482, 602092, 605117, 607694, 622668, 625556, 682234, 726487, 726543, 726553);
|
17.94 ms (15.42%)
|
1 |
SELECT p.post_id, p.user_id, p.content_id, p.public_key, p.search_field, p.cover, p.type, p.sexual_orientation, p.orientation, p.quality, p.noindex, p.nofollow, p.contents_num, p.duration, p.likes, p.dislikes, p.views, p.vote_rating, p.params, p.published_at, IFNULL(`r`.`title`, `f`.`title`) as `title`, IFNULL(`r`.`custom1`, `f`.`custom1`) as `custom1`, IFNULL(`r`.`custom2`, `f`.`custom2`) as `custom2` FROM post p LEFT JOIN post_translation f ON `p`.`post_id` = `f`.`post_id` AND `f`.`lang_id`=? LEFT JOIN post_translation r ON `p`.`post_id` = `r`.`post_id` AND `r`.`lang_id`=? WHERE p.post_id IN (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Parameters: [
1
2
439514
455117
455505
476586
453402
414779
523358
502598
528022
579707
556577
607694
605117
453394
455719
520672
564162
504757
529409
515063
574413
559682
726543
726553
455479
450990
442612
519346
602092
726487
425959
429899
524029
682234
447031
529392
492799
558338
599482
625556
425214
450901
485276
589634
455151
458419
582269
589683
562061
525337
561458
562531
591197
509415
518597
518599
464566
622668
]
SELECT
p.post_id,
p.user_id,
p.content_id,
p.public_key,
p.search_field,
p.cover,
p.type,
p.sexual_orientation,
p.orientation,
p.quality,
p.noindex,
p.nofollow,
p.contents_num,
p.duration,
p.likes,
p.dislikes,
p.views,
p.vote_rating,
p.params,
p.published_at,
IFNULL(`r`.`title`, `f`.`title`) as `title`,
IFNULL(`r`.`custom1`, `f`.`custom1`) as `custom1`,
IFNULL(`r`.`custom2`, `f`.`custom2`) as `custom2`
FROM
post p
LEFT JOIN post_translation f ON `p`.`post_id` = `f`.`post_id`
AND `f`.`lang_id` = ?
LEFT JOIN post_translation r ON `p`.`post_id` = `r`.`post_id`
AND `r`.`lang_id` = ?
WHERE
p.post_id IN (
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?
)
SELECT p.post_id, p.user_id, p.content_id, p.public_key, p.search_field, p.cover, p.type, p.sexual_orientation, p.orientation, p.quality, p.noindex, p.nofollow, p.contents_num, p.duration, p.likes, p.dislikes, p.views, p.vote_rating, p.params, p.published_at, IFNULL(`r`.`title`, `f`.`title`) as `title`, IFNULL(`r`.`custom1`, `f`.`custom1`) as `custom1`, IFNULL(`r`.`custom2`, `f`.`custom2`) as `custom2` FROM post p LEFT JOIN post_translation f ON `p`.`post_id` = `f`.`post_id` AND `f`.`lang_id`=1 LEFT JOIN post_translation r ON `p`.`post_id` = `r`.`post_id` AND `r`.`lang_id`=2 WHERE p.post_id IN (439514, 455117, 455505, 476586, 453402, 414779, 523358, 502598, 528022, 579707, 556577, 607694, 605117, 453394, 455719, 520672, 564162, 504757, 529409, 515063, 574413, 559682, 726543, 726553, 455479, 450990, 442612, 519346, 602092, 726487, 425959, 429899, 524029, 682234, 447031, 529392, 492799, 558338, 599482, 625556, 425214, 450901, 485276, 589634, 455151, 458419, 582269, 589683, 562061, 525337, 561458, 562531, 591197, 509415, 518597, 518599, 464566, 622668);
|
2.72 ms (2.34%)
|
1 |
SELECT pht.post_id, pht.tag_id, t.slug, IFNULL(`r`.`name`, `f`.`name`) as `name` FROM post_has_tag pht INNER JOIN tag t ON pht.tag_id = t.tag_id AND t.enabled = 1 LEFT JOIN tag_translation f ON t.tag_id = f.tag_id AND f.lang_id=? LEFT JOIN tag_translation r ON `t`.`tag_id` = `r`.`tag_id` AND `r`.`lang_id`=? WHERE pht.post_id IN (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
Parameters: [
1
2
414779
425214
425959
429899
439514
442612
447031
450901
450990
453394
453402
455117
455151
455479
455505
455719
458419
464566
476586
485276
492799
502598
504757
509415
515063
518597
518599
519346
520672
523358
524029
525337
528022
529392
529409
556577
558338
559682
561458
562061
562531
564162
574413
579707
582269
589634
589683
591197
599482
602092
605117
607694
622668
625556
682234
726487
726543
726553
]
SELECT
pht.post_id,
pht.tag_id,
t.slug,
IFNULL(`r`.`name`, `f`.`name`) as `name`
FROM
post_has_tag pht
INNER JOIN tag t ON pht.tag_id = t.tag_id
AND t.enabled = 1
LEFT JOIN tag_translation f ON t.tag_id = f.tag_id
AND f.lang_id = ?
LEFT JOIN tag_translation r ON `t`.`tag_id` = `r`.`tag_id`
AND `r`.`lang_id` = ?
WHERE
pht.post_id IN (
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?
)
SELECT pht.post_id, pht.tag_id, t.slug, IFNULL(`r`.`name`, `f`.`name`) as `name` FROM post_has_tag pht INNER JOIN tag t ON pht.tag_id = t.tag_id AND t.enabled = 1 LEFT JOIN tag_translation f ON t.tag_id = f.tag_id AND f.lang_id=1 LEFT JOIN tag_translation r ON `t`.`tag_id` = `r`.`tag_id` AND `r`.`lang_id`=2 WHERE pht.post_id IN (414779, 425214, 425959, 429899, 439514, 442612, 447031, 450901, 450990, 453394, 453402, 455117, 455151, 455479, 455505, 455719, 458419, 464566, 476586, 485276, 492799, 502598, 504757, 509415, 515063, 518597, 518599, 519346, 520672, 523358, 524029, 525337, 528022, 529392, 529409, 556577, 558338, 559682, 561458, 562061, 562531, 564162, 574413, 579707, 582269, 589634, 589683, 591197, 599482, 602092, 605117, 607694, 622668, 625556, 682234, 726487, 726543, 726553);
|