fixed schema creation

This commit is contained in:
Sascha Kühl
2025-12-04 16:06:39 +01:00
parent 19eb54df8d
commit 980cabe94f
12 changed files with 152 additions and 95 deletions
+7
View File
@@ -43,6 +43,13 @@ const std::string& object::alias() const {
void object::update_name(const std::string& name) {
name_ = name;
for (auto& con : constraints_) {
if (con.is_primary_key_constraint()) {
con.name_ += name;
} else if (con.is_foreign_key_constraint()) {
con.name_ = "FK_" + name + "_" + con.column_name();
}
}
}
bool object::has_attributes() const {