Skip to content

Commit 593badd

Browse files
author
Neil Conway
committed
Correct an omission in the syntax error message emitted by EXECUTE INTO
in pl/pgsql.
1 parent fbc4edf commit 593badd

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

src/pl/plpgsql/src/gram.y

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
* procedural language
55
*
66
* IDENTIFICATION
7-
* $PostgreSQL: pgsql/src/pl/plpgsql/src/gram.y,v 1.73 2005/06/07 02:47:16 neilc Exp $
7+
* $PostgreSQL: pgsql/src/pl/plpgsql/src/gram.y,v 1.74 2005/06/08 00:49:36 neilc Exp $
88
*
99
* This software is copyrighted by Jan Wieck - Hamburg.
1010
*
@@ -1263,13 +1263,12 @@ stmt_dynexecute : K_EXECUTE lno
12631263
new->cmd_type = PLPGSQL_STMT_DYNEXECUTE;
12641264
new->lineno = $2;
12651265
new->query = expr;
1266-
12671266
new->rec = NULL;
12681267
new->row = NULL;
12691268

12701269
/*
1271-
* If we saw "INTO", look for an additional
1272-
* row or record var.
1270+
* If we saw "INTO", look for a following row
1271+
* var, record var, or list of scalars.
12731272
*/
12741273
if (endtoken == K_INTO)
12751274
{
@@ -1293,9 +1292,9 @@ stmt_dynexecute : K_EXECUTE lno
12931292
plpgsql_error_lineno = $2;
12941293
ereport(ERROR,
12951294
(errcode(ERRCODE_SYNTAX_ERROR),
1296-
errmsg("syntax error at \"%s\"",
1297-
yytext),
1298-
errdetail("Expected record or row variable.")));
1295+
errmsg("syntax error at \"%s\"", yytext),
1296+
errdetail("Expected record variable, row variable, "
1297+
"or list of scalar variables.")));
12991298
}
13001299
if (yylex() != ';')
13011300
yyerror("syntax error");

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy