不要怂,就是干,撸起袖子干!

Commit 5f5eb36c by Mick Hansen

ORDER BY in the sub-query should also be in the main-query

1 parent b7f478c4
Showing with 1 additions and 2 deletions
...@@ -774,9 +774,8 @@ module.exports = (function() { ...@@ -774,9 +774,8 @@ module.exports = (function() {
options.order.forEach(function (t) { options.order.forEach(function (t) {
if (subQuery && !(t[0] instanceof daoFactory)) { if (subQuery && !(t[0] instanceof daoFactory)) {
subQueryOrder.push(this.quote(t, factory)) subQueryOrder.push(this.quote(t, factory))
} else {
mainQueryOrder.push(this.quote(t, factory))
} }
mainQueryOrder.push(this.quote(t, factory))
}.bind(this)) }.bind(this))
} else { } else {
mainQueryOrder.push(options.order) mainQueryOrder.push(options.order)
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!