aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2016-08-03 17:41:02 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2016-08-03 17:41:02 +0200
commitfa085bca16a685b768e091c7c352e97677b4d8ff (patch)
tree66e834b8ca029805f5bc065ba2cd2149f1083e85
parent43be5cc232738c05b71ff550c8064ff8bb484a3c (diff)
Recognize WITH as beginning of complete query
-rw-r--r--odb/pgsql/query.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/odb/pgsql/query.cxx b/odb/pgsql/query.cxx
index de53632..3dac228 100644
--- a/odb/pgsql/query.cxx
+++ b/odb/pgsql/query.cxx
@@ -271,7 +271,9 @@ namespace odb
s.compare (0, (n = 8), "GROUP BY") == 0 ||
s.compare (0, (n = 8), "group by") == 0 ||
s.compare (0, (n = 6), "HAVING") == 0 ||
- s.compare (0, (n = 6), "having") == 0)
+ s.compare (0, (n = 6), "having") == 0 ||
+ s.compare (0, (n = 4), "WITH") == 0 ||
+ s.compare (0, (n = 4), "with") == 0)
{
// It either has to be an exact match, or there should be
// a whitespace following the keyword.