feat: UPDATE route routes-by-agency-id

This commit is contained in:
dancingCycle 2023-11-24 22:03:23 +01:00
parent cdfa348c59
commit b0e6938578
1 changed files with 1 additions and 1 deletions

View File

@ -4,7 +4,7 @@ const db = require('./db');
async function get(agencyId = 0) {
const schema = process.env.DB_SCHEMA || 'schema';
const query = `SELECT routes.route_id, routes.route_short_name, routes.route_long_name FROM ` + schema + `.routes WHERE agency_id='${agencyId}';`;
const query = `SELECT routes.route_id, routes.route_short_name, routes.route_long_name FROM ` + schema + `.routes WHERE agency_id='${agencyId}' ORDER BY routes.route_short_name;`;
return await db.query(query);
};