Skip to content

Commit 0fe1f41

Browse files
committed
chore: include view in PG
1 parent 2293727 commit 0fe1f41

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/lib/connectors/postgres/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ const getTableSchema = async (connection: Connection, databaseName: string): Pro
9696
connection.database = databaseName;
9797
const client = await newPostgresClient(connection);
9898
const { rows } = await client.query(
99-
`SELECT table_schema, table_name FROM information_schema.tables WHERE table_schema NOT IN (${systemSchemas}) AND table_name NOT IN (${systemTables}) AND table_type='BASE TABLE' AND table_catalog=$1;`,
99+
`SELECT table_schema, table_name FROM information_schema.tables WHERE table_schema NOT IN (${systemSchemas}) AND table_name NOT IN (${systemTables}) AND (table_type='BASE TABLE' or table_type='VIEW') AND table_catalog=$1;`,
100100
[databaseName]
101101
);
102102

0 commit comments

Comments
 (0)