fix: add schema to tables

This commit is contained in:
Nybkox
2025-05-07 00:13:40 +02:00
parent 839ec9a456
commit 3e2840ca15
2 changed files with 5 additions and 2 deletions

View File

@@ -38,7 +38,9 @@ class Analyser extends DatabaseAnalyser {
return { return {
tables: tables.map(table => ({ tables: tables.map(table => ({
...table, ...table,
columns: columns.filter(column => column.tableName === table.pureName), columns: columns.filter(
column => column.tableName === table.pureName && column.schemaName === table.schemaName
),
})), })),
}; };
} }

View File

@@ -2,7 +2,8 @@ module.exports = `
SELECT SELECT
TRIM(RDB$RELATION_NAME) AS pureName, TRIM(RDB$RELATION_NAME) AS pureName,
RDB$DESCRIPTION AS objectComment, RDB$DESCRIPTION AS objectComment,
RDB$FORMAT AS objectTypeField RDB$FORMAT AS objectTypeField,
RDB$OWNER_NAME AS schemaName
FROM RDB$RELATIONS FROM RDB$RELATIONS
WHERE RDB$SYSTEM_FLAG = 0 -- only user-defined tables WHERE RDB$SYSTEM_FLAG = 0 -- only user-defined tables
ORDER BY pureName; ORDER BY pureName;