@@ -9071,7 +9071,7 @@ getTableAttrs(Archive *fout, TableInfo *tblinfo, int numTables)
90719071			tbinfo->attoptions[j] = pg_strdup(PQgetvalue(res, r, i_attoptions));
90729072			tbinfo->attcollation[j] = atooid(PQgetvalue(res, r, i_attcollation));
90739073			tbinfo->attcompression[j] = *(PQgetvalue(res, r, i_attcompression));
9074- 			tbinfo->attisinvisible[j] = (PQgetvalue(res, j , i_attisinvisible)[0] == 't');
9074+ 			tbinfo->attisinvisible[j] = (PQgetvalue(res, r , i_attisinvisible)[0] == 't');
90759075			tbinfo->attfdwoptions[j] = pg_strdup(PQgetvalue(res, r, i_attfdwoptions));
90769076			tbinfo->attmissingval[j] = pg_strdup(PQgetvalue(res, r, i_attmissingval));
90779077			tbinfo->attrdefs[j] = NULL; /* fix below */
@@ -16306,6 +16306,10 @@ dumpTableSchema(Archive *fout, const TableInfo *tbinfo)
1630616306							appendPQExpBuffer(q, " COLLATE %s",
1630716307											  fmtQualifiedDumpable(coll));
1630816308					}
16309+ 
16310+ 					if (tbinfo->attisinvisible[j])
16311+ 						appendPQExpBufferStr(q, " INVISIBLE");
16312+ 
1630916313					is_ora_identity = false;
1631016314				}
1631116315			}
@@ -16695,12 +16699,6 @@ dumpTableSchema(Archive *fout, const TableInfo *tbinfo)
1669516699								  foreign, qualrelname,
1669616700								  fmtId(tbinfo->attnames[j]));
1669716701
16698- 			/*
16699- 			 * Dump per-column invisible information.
16700- 			 */
16701- 			if (tbinfo->attisinvisible[j])
16702- 				appendPQExpBufferStr(q, " INVISIBLE");
16703- 
1670416702			/*
1670516703			 * Dump per-column statistics information. We only issue an ALTER
1670616704			 * TABLE statement if the attstattarget entry for this column is
0 commit comments