summaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
authoryehzu <yehzu2@gmail.com>2020-02-25 20:43:26 +0800
committeryehzu <yehzu2@gmail.com>2020-02-25 20:43:26 +0800
commit5dae3c64a3f9f4a72640e6a0e9e7413e4a7e97ce (patch)
tree70a386f37988df35a08e27208470764352a87aca /client
parentfcb443e2aeaed0e592f8ba02402fb419202edc07 (diff)
fix incorrect comma between orderBy and limit/offset/timeout
Diffstat (limited to 'client')
-rw-r--r--client/src/main/java/ai/vespa/client/dsl/EndQuery.java2
-rw-r--r--client/src/test/groovy/ai/vespa/client/dsl/QTest.groovy2
2 files changed, 2 insertions, 2 deletions
diff --git a/client/src/main/java/ai/vespa/client/dsl/EndQuery.java b/client/src/main/java/ai/vespa/client/dsl/EndQuery.java
index 4facf6ce0fb..2af1e0bb49d 100644
--- a/client/src/main/java/ai/vespa/client/dsl/EndQuery.java
+++ b/client/src/main/java/ai/vespa/client/dsl/EndQuery.java
@@ -177,7 +177,7 @@ public class EndQuery {
} else if (others.isEmpty()) {
sb.append("order by ").append(orderStr);
} else {
- sb.append("order by ").append(orderStr).append(", ").append(others);
+ sb.append("order by ").append(orderStr).append(" ").append(others);
}
if (groupQueryStr != null) {
diff --git a/client/src/test/groovy/ai/vespa/client/dsl/QTest.groovy b/client/src/test/groovy/ai/vespa/client/dsl/QTest.groovy
index e363a9bcc13..19c87d6aecd 100644
--- a/client/src/test/groovy/ai/vespa/client/dsl/QTest.groovy
+++ b/client/src/test/groovy/ai/vespa/client/dsl/QTest.groovy
@@ -59,7 +59,7 @@ class QTest extends Specification {
.build()
expect:
- q == """yql=select * from sd1 where f1 contains "v1" and f2 contains "v2" or f3 contains "v3" and !(f4 contains "v4") order by f1 desc, f2 asc, limit 2 offset 1 timeout 3;&paramk1=paramv1"""
+ q == """yql=select * from sd1 where f1 contains "v1" and f2 contains "v2" or f3 contains "v3" and !(f4 contains "v4") order by f1 desc, f2 asc limit 2 offset 1 timeout 3;&paramk1=paramv1"""
}
def "matches"() {