fix(postgres): handle PostgreSQL views

This commit is contained in:
ptma authored and GitHub committed 2026-06-25 10:54:38 +08:00
1 parent 2999d9c56f
commit 484d20922a
7 files changed
+19 -16

No files matched your search

+4 -4
View File
@@ -263,25 +263,25 @@ fn diff_schema(options: &SchemaDiffPreparationOptions) -> Vec<TableDiff> {
let source_table_names: Vec<String> = options
.source_tables
.iter()
.filter(|table| table.table_type != "VIEW")
.filter(|table| !table.table_type.contains("VIEW"))
.map(|table| table.name.clone())
.collect();
let target_table_names: Vec<String> = options
.target_tables
.iter()
.filter(|table| table.table_type != "VIEW")
.filter(|table| !table.table_type.contains("VIEW"))
.map(|table| table.name.clone())
.collect();
let source_view_names: Vec<String> = options
.source_tables
.iter()
.filter(|table| table.table_type == "VIEW")
.filter(|table| table.table_type.contains("VIEW"))
.map(|table| table.name.clone())
.collect();
let target_view_names: Vec<String> = options
.target_tables
.iter()
.filter(|table| table.table_type == "VIEW")
.filter(|table| table.table_type.contains("VIEW"))
.map(|table| table.name.clone())
.collect();