Index: gram.y =================================================================== RCS file: /usr/local/cvsroot/pgsql/src/backend/parser/gram.y,v retrieving revision 2.106 diff -c -r2.106 gram.y *** gram.y 1999/10/03 23:55:30 2.106 --- gram.y 1999/10/05 18:01:41 *************** *** 365,384 **** %left UNION INTERSECT EXCEPT %% ! stmtblock: stmtmulti opt_semi { parsetree = $1; } ; stmtmulti: stmtmulti ';' stmt ! { $$ = lappend($1, $3); } | stmt ! { $$ = lcons($1,NIL); } ; - opt_semi: ';' - | /*EMPTY*/ - ; - stmt : AddAttrStmt | AlterUserStmt | ClosePortalStmt --- 365,393 ---- %left UNION INTERSECT EXCEPT %% ! /* ! * Handle comment-only lines, and ;; SELECT * FROM pg_class ;;; ! * psql already handles such cases, but other interfaces don't. ! * bjm 1999/10/05 ! */ ! stmtblock: stmtmulti { parsetree = $1; } ; stmtmulti: stmtmulti ';' stmt ! { if ($3 != (Node *)NIL) ! $$ = lappend($1, $3); ! else ! $$ = $1; ! } | stmt ! { if ($1 != (Node *)NIL) ! $$ = lcons($1,NIL); ! else ! $$ = (Node *)NIL; ! } ; stmt : AddAttrStmt | AlterUserStmt | ClosePortalStmt *************** *** 423,428 **** --- 432,439 ---- | VariableShowStmt | VariableResetStmt | ConstraintsSetStmt + | /*EMPTY*/ + { $$ = (Node *)NIL; } ; /*****************************************************************************