fixed loading structure for firebird

This commit is contained in:
SPRINX0\prochazka
2025-09-25 08:59:12 +02:00
parent aec692c402
commit d7dbd79f7c
5 changed files with 4 additions and 6 deletions

View File

@@ -124,7 +124,7 @@ class Analyser extends DatabaseAnalyser {
uniques: uniques.filter(unique => unique.pureName === table.pureName),
indexes: indexes.filter(index => index.pureName === table.pureName),
})) ?? [];
console.log(uniques);
// console.log(uniques);
const views =
viewsResults.rows?.map(view => ({

View File

@@ -126,7 +126,5 @@ module.exports = {
getTriggerTiming,
getFormattedDefaultValue,
getTriggerCreateSql,
blobStreamToString,
normalizeRow,
createFirebirdInsertStream,
};

View File

@@ -4,7 +4,7 @@ SELECT
TRIM(F.RDB$FUNCTION_NAME) AS "objectId",
TRIM('FUNCTION') AS "objectTypeField",
TRIM(F.RDB$DESCRIPTION) AS "objectComment",
F.RDB$FUNCTION_SOURCE AS "createSql", -- This is the PSQL body or definition for UDRs
CAST(SUBSTRING(F.RDB$FUNCTION_SOURCE FROM 1 FOR 5000) AS VARCHAR(5000)) AS "createSql",
FALSE AS "requiresFormat" -- Assuming PSQL source is generally readable
FROM
RDB$FUNCTIONS F

View File

@@ -11,7 +11,7 @@ SELECT -- Index name, maps to pureName
WHEN I.RDB$EXPRESSION_SOURCE IS NOT NULL THEN TRIM('expression') -- indexType: if an expression index [cite: 46, 262]
ELSE TRIM('normal')
END AS "indexType",
I.RDB$CONDITION_SOURCE AS "idx_filterDefinition", -- filterDefinition: for partial indexes [cite: 46, 261, 838]
-- I.RDB$CONDITION_SOURCE AS "idx_filterDefinition", -- filterDefinition: for partial indexes [cite: 46, 261, 838]
COALESCE(I.RDB$INDEX_INACTIVE, 0) AS "idx_isInactive", -- 0 for active, 1 for inactive [cite: 46, 838]
I.RDB$DESCRIPTION AS "idx_description", -- Index description/comment [cite: 46, 838]

View File

@@ -3,7 +3,7 @@ SELECT
TRIM(P.RDB$PROCEDURE_NAME) AS "pureName",
TRIM('PROCEDURE') AS "objectTypeField",
TRIM(P.RDB$DESCRIPTION) AS "objectComment",
P.RDB$PROCEDURE_SOURCE AS "createSql", -- Contains the PSQL body
CAST(SUBSTRING(P.RDB$PROCEDURE_SOURCE FROM 1 FOR 5000) AS VARCHAR(5000)) AS "createSql",
FALSE AS "requiresFormat"
FROM
RDB$PROCEDURES P