diff options
author | Carlo Zancanaro <carlo@clearboxsystems.com.au> | 2013-07-06 13:55:49 +1000 |
---|---|---|
committer | Carlo Zancanaro <carlo@clearboxsystems.com.au> | 2013-07-06 13:55:49 +1000 |
commit | d91170319be957b9202eaefd5153883d22ba6f38 (patch) | |
tree | 99577b1b1c1abb32b1bea003d1cdb8afb92e0f1e /src/clojure_sql/dsl.clj | |
parent | 6018063412cef2fa3895b04adb789fc43b9e3f40 (diff) |
Make `sort` able to take expressions rather than just table names.
Diffstat (limited to 'src/clojure_sql/dsl.clj')
-rw-r--r-- | src/clojure_sql/dsl.clj | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/clojure_sql/dsl.clj b/src/clojure_sql/dsl.clj index c94f678..35f296f 100644 --- a/src/clojure_sql/dsl.clj +++ b/src/clojure_sql/dsl.clj @@ -311,8 +311,8 @@ (assoc query :sort (for [field fields-seq] (if (vector? field) - [(resolve-field table-name fields-lookup (first field)) (second field)] - [(resolve-field table-name fields-lookup field) :asc]))))) + [(process-expression table-name fields-lookup (first field)) (second field)] + [(process-expression table-name fields-lookup field) :asc]))))) (defn group "Apply a grouping to a query. |