diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2007-02-19 07:03:34 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2007-02-19 07:03:34 +0000 |
commit | 7c5e5439d2a64ee82d54be2e064a4bb4602bad30 (patch) | |
tree | da8d85b50e284413823da3bc98975c03278cb582 /src/backend/optimizer/prep/preptlist.c | |
parent | 90c301aaa9377d385d00d93462f3f656ada8981e (diff) |
Get rid of some old and crufty global variables in the planner. When
this code was last gone over, there wasn't really any alternative to
globals because we didn't have the PlannerInfo struct being passed all
through the planner code. Now that we do, we can restructure things
to avoid non-reentrancy. I'm fooling with this because otherwise I'd
have had to add another global variable for the planned compact
range table list.
Diffstat (limited to 'src/backend/optimizer/prep/preptlist.c')
-rw-r--r-- | src/backend/optimizer/prep/preptlist.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/optimizer/prep/preptlist.c b/src/backend/optimizer/prep/preptlist.c index b8d98cc9e3c..310b57392cd 100644 --- a/src/backend/optimizer/prep/preptlist.c +++ b/src/backend/optimizer/prep/preptlist.c @@ -16,7 +16,7 @@ * Portions Copyright (c) 1994, Regents of the University of California * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/optimizer/prep/preptlist.c,v 1.85 2007/01/05 22:19:32 momjian Exp $ + * $PostgreSQL: pgsql/src/backend/optimizer/prep/preptlist.c,v 1.86 2007/02/19 07:03:30 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -124,7 +124,7 @@ preprocess_targetlist(PlannerInfo *root, List *tlist) /* * Currently the executor only supports FOR UPDATE/SHARE at top level */ - if (PlannerQueryLevel > 1) + if (root->query_level > 1) ereport(ERROR, (errcode(ERRCODE_FEATURE_NOT_SUPPORTED), errmsg("SELECT FOR UPDATE/SHARE is not allowed in subqueries"))); |