From 608c3802423905eb61b4f9b0e9c337c6800c4a6d Mon Sep 17 00:00:00 2001 From: fgs21 <fgs21@inf.ufpr.br> Date: Wed, 28 Feb 2024 10:32:28 -0300 Subject: [PATCH] [TEST] Trying to modify the order of 'order by' in query exec --- src/libs/routes_v1/newPnad.js | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/libs/routes_v1/newPnad.js b/src/libs/routes_v1/newPnad.js index 720f3646..c5756a4d 100644 --- a/src/libs/routes_v1/newPnad.js +++ b/src/libs/routes_v1/newPnad.js @@ -297,16 +297,6 @@ rqf.addField({ foreign: 'cod_uf', foreignTable: 'pnad_novo' } -}).addValue({ - name: 'illiteracy', - table: 'pnad_novo', - tableField: 'analfabetismo', - resultField: 'illiteracy_id', - where: { - relation: '=', - type: 'integer', - field: 'analfabetismo' - } }).addValue({ name: 'years_of_study', table: 'pnad_novo', @@ -367,6 +357,16 @@ rqf.addField({ type: 'integer', field: 'nivel_etapa_modalidade_freq' } +}).addValue({ + name: 'illiteracy', + table: 'pnad_novo', + tableField: 'analfabetismo', + resultField: 'illiteracy_id', + where: { + relation: '=', + type: 'integer', + field: 'analfabetismo' + } }).addValue({ name: 'modality_shift', table: 'pnad_novo', @@ -518,6 +518,6 @@ PnadNovoApp.get('/', rqf.parse(), rqf.build(), (req, res, next) => { .order('pnad_novo.ano_ref') console.log(req.sql.toString()) next(); -}, query, id2str.transform(false),response('pnad_novo')); +}, query, id2str.transform(false), response('pnad_novo')); module.exports = PnadNovoApp; -- GitLab