File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -1615,12 +1615,13 @@ check_for_not_null_inheritance(ClusterInfo *cluster)
1615
1615
PGconn * conn = connectToServer (& old_cluster , active_db -> db_name );
1616
1616
1617
1617
res = executeQueryOrDie (conn ,
1618
- "SELECT cc.relnamespace::pg_catalog.regnamespace AS nspname, "
1619
- " cc.relname, ac.attname "
1618
+ "SELECT nspname, cc.relname, ac.attname "
1620
1619
"FROM pg_catalog.pg_inherits i, pg_catalog.pg_attribute ac, "
1621
- " pg_catalog.pg_attribute ap, pg_catalog.pg_class cc "
1620
+ " pg_catalog.pg_attribute ap, pg_catalog.pg_class cc, "
1621
+ " pg_catalog.pg_namespace nc "
1622
1622
"WHERE cc.oid = ac.attrelid AND i.inhrelid = ac.attrelid "
1623
1623
" AND i.inhparent = ap.attrelid AND ac.attname = ap.attname "
1624
+ " AND cc.relnamespace = nc.oid "
1624
1625
" AND ap.attnum > 0 and ap.attnotnull AND NOT ac.attnotnull" );
1625
1626
1626
1627
ntup = PQntuples (res );
You can’t perform that action at this time.
0 commit comments