diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2006-03-23 00:19:30 +0000 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2006-03-23 00:19:30 +0000 |
| commit | 19956e0d5388b11a1cc3eaf2dbf628aa531ce331 (patch) | |
| tree | f2c7071f4daee4588d4c004d809bd327baa4adde /src/include | |
| parent | a3f0b3d68f9a5357a3f72b40a45bcc714a9e0649 (diff) | |
| download | postgresql-19956e0d5388b11a1cc3eaf2dbf628aa531ce331.tar.gz | |
Add error location info to ResTarget parse nodes. Allows error cursor to be supplied
for various mistakes involving INSERT and UPDATE target columns.
Diffstat (limited to 'src/include')
| -rw-r--r-- | src/include/nodes/parsenodes.h | 3 | ||||
| -rw-r--r-- | src/include/parser/parse_target.h | 5 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/include/nodes/parsenodes.h b/src/include/nodes/parsenodes.h index aea32d236d..d6f7c4a95a 100644 --- a/src/include/nodes/parsenodes.h +++ b/src/include/nodes/parsenodes.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/nodes/parsenodes.h,v 1.305 2006/03/16 00:31:55 tgl Exp $ + * $PostgreSQL: pgsql/src/include/nodes/parsenodes.h,v 1.306 2006/03/23 00:19:30 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -327,6 +327,7 @@ typedef struct ResTarget char *name; /* column name or NULL */ List *indirection; /* subscripts and field names, or NIL */ Node *val; /* the value expression to compute or assign */ + int location; /* token location, or -1 if unknown */ } ResTarget; /* diff --git a/src/include/parser/parse_target.h b/src/include/parser/parse_target.h index f66850da23..f1cb2bd8a1 100644 --- a/src/include/parser/parse_target.h +++ b/src/include/parser/parse_target.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/parser/parse_target.h,v 1.38 2006/03/05 15:58:57 momjian Exp $ + * $PostgreSQL: pgsql/src/include/parser/parse_target.h,v 1.39 2006/03/23 00:19:30 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -24,7 +24,8 @@ extern TargetEntry *transformTargetEntry(ParseState *pstate, char *colname, bool resjunk); extern void updateTargetListEntry(ParseState *pstate, TargetEntry *tle, char *colname, int attrno, - List *indirection); + List *indirection, + int location); extern List *checkInsertTargets(ParseState *pstate, List *cols, List **attrnos); extern TupleDesc expandRecordVariable(ParseState *pstate, Var *var, |
