aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/odbc/parse.c
diff options
context:
space:
mode:
authorHiroshi Inoue <inoue@tpf.co.jp>2002-08-01 03:07:50 +0000
committerHiroshi Inoue <inoue@tpf.co.jp>2002-08-01 03:07:50 +0000
commit7dfc7e9e8cf7e480948b68e7fbb12577e18e84e4 (patch)
treeee67e41f0668736b54c25f45d55c46e5a7532956 /src/interfaces/odbc/parse.c
parentce7565ab91100747d250ef67d72af5c1b01150d4 (diff)
downloadpostgresql-7dfc7e9e8cf7e480948b68e7fbb12577e18e84e4.tar.gz
postgresql-7dfc7e9e8cf7e480948b68e7fbb12577e18e84e4.zip
1) Improve the handling of the queries like (select ..) union (select ..)
whose first non-space character is '('. 2) Handle Insert .. () VALUES ().
Diffstat (limited to 'src/interfaces/odbc/parse.c')
-rw-r--r--src/interfaces/odbc/parse.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/interfaces/odbc/parse.c b/src/interfaces/odbc/parse.c
index b2661d5379d..a61b75e90cf 100644
--- a/src/interfaces/odbc/parse.c
+++ b/src/interfaces/odbc/parse.c
@@ -873,6 +873,11 @@ parse_statement(StatementClass *stmt)
mylog("--------------------------------------------\n");
mylog("nfld=%d, ntab=%d\n", irdflds->nfields, stmt->ntab);
+ if (0 == stmt->ntab)
+ {
+ stmt->parse_status = STMT_PARSE_FATAL;
+ return FALSE;
+ }
for (i = 0; i < (int) irdflds->nfields; i++)
{