Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite5a8da0

Browse files
committed
Please apply the patch at the end. Disables use of system columns of views at all (not only oid, cmin etc. too). pgsql=> select cmin from pg_rules; ERROR: system column cmin not available - pg_rules is a view pgsql=> select * from pg_rules where pg_rules.oid = pg_class.oid; ERROR: system column oid not available - pg_rules is a view pgsql=>Jan
1 parent2da5e59 commite5a8da0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

‎src/backend/rewrite/rewriteHandler.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
*
77
*
88
* IDENTIFICATION
9-
* $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteHandler.c,v 1.22 1998/10/0216:27:47 momjian Exp $
9+
* $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteHandler.c,v 1.23 1998/10/0221:53:39 momjian Exp $
1010
*
1111
*-------------------------------------------------------------------------
1212
*/
@@ -1777,6 +1777,8 @@ apply_RIR_view(Node **nodePtr, int rt_index, RangeTblEntry *rte, List *tlist, in
17771777
var->varno==rt_index) {
17781778
Node*exp;
17791779

1780+
if (var->varattno<0)
1781+
elog(ERROR,"system column %s not available - %s is a view",get_attname(rte->relid,var->varattno),rte->relname);
17801782
exp=FindMatchingTLEntry(
17811783
tlist,
17821784
get_attname(rte->relid,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp