summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAshutosh Bapat2012-07-17 08:40:35 +0000
committerAshutosh Bapat2012-07-17 08:40:35 +0000
commit4371aadf993ff4fce458362b0de8d848bbe96e4a (patch)
tree68fae2574f62cd69f29391d803fe8a69aa2970b7 /src
parent5655bc5b45a90c6500a375c789d34b07039b6d2b (diff)
validate_part_col_updatable() was falsely assuming that the table with no
location info is as good as non-existent table. This assumption is not true for catalogs or coordinator only tables. In such cases, this function should not look for any distribution column, since one can not exist for a table local to the coordinator.
Diffstat (limited to 'src')
-rw-r--r--src/backend/pgxc/plan/planner.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/backend/pgxc/plan/planner.c b/src/backend/pgxc/plan/planner.c
index 8ef63d8a88..7cd46d8e0b 100644
--- a/src/backend/pgxc/plan/planner.c
+++ b/src/backend/pgxc/plan/planner.c
@@ -1984,10 +1984,9 @@ validate_part_col_updatable(const Query *query)
/* See if we have the partitioned case. */
rel_loc_info = GetRelationLocInfo(rte->relid);
+ /* Any column updation on local relations is fine */
if (!rel_loc_info)
- ereport(ERROR,
- (errcode(ERRCODE_STATEMENT_TOO_COMPLEX),
- (errmsg("Could not find relation for oid = %d", rte->relid))));
+ return;
/* Only LOCATOR_TYPE_HASH & LOCATOR_TYPE_MODULO should be checked */