mirror of
https://github.com/shlinkio/shlink.git
synced 2024-12-23 07:33:58 -06:00
Fix ordering on Postgres
This commit is contained in:
parent
dd049feb40
commit
49b6063501
@ -107,8 +107,8 @@ class TagRepository extends EntitySpecificationRepository implements TagReposito
|
|||||||
->select(
|
->select(
|
||||||
't.id_0 AS id',
|
't.id_0 AS id',
|
||||||
't.name_1 AS name',
|
't.name_1 AS name',
|
||||||
'v.visits',
|
'COALESCE(v.visits, 0) AS visits', // COALESCE required for postgres to properly order
|
||||||
'v2.non_bot_visits',
|
'COALESCE(v2.non_bot_visits, 0) AS non_bot_visits', // COALESCE required for postgres to properly order
|
||||||
'COUNT(DISTINCT s.id) AS short_urls_count',
|
'COUNT(DISTINCT s.id) AS short_urls_count',
|
||||||
)
|
)
|
||||||
->from('(' . $subQb->getQuery()->getSQL() . ')', 't') // @phpstan-ignore-line
|
->from('(' . $subQb->getQuery()->getSQL() . ')', 't') // @phpstan-ignore-line
|
||||||
|
Loading…
Reference in New Issue
Block a user