Skip to content

Commit

Permalink
fix: population sort on city search
Browse files Browse the repository at this point in the history
  • Loading branch information
evanp committed Nov 27, 2024
1 parent 238d313 commit 83a1bab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/routes/search.routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ async function searchCity(res: any, q: string) {
const isLowercase = q[0] === q[0].toLowerCase();

const result = await sequelize.query(
`SELECT DISTINCT a.actor_id
`SELECT DISTINCT a.actor_id, lp.population
FROM
"Actor" a JOIN "ActorName" an ON a.actor_id = an.actor_id
LEFT JOIN "LatestPopulation" lp ON a.actor_id = lp.actor_id
Expand Down

0 comments on commit 83a1bab

Please sign in to comment.