Appearance
CreateForeignKeys Method
Definition
- Namespace:
JASE.Database - Assembly:
JASE.Database.dll
Overloads
| Name | Description |
|---|---|
string CreateForeignKeys(ITableInfo table) | Generate SQL that adds all valid foreign-key constraints on table. Returns null when the table has no foreign keys to emit. |
string CreateForeignKeys(TableDifferences differences) | Generate SQL that applies foreign-key changes from a compare result (drops then adds). Returns null when there is no FK work. |
string CreateForeignKeys(ITableInfo table)
csharp
string CreateForeignKeys(ITableInfo table)Generate SQL that adds all valid foreign-key constraints on table. Returns null when the table has no foreign keys to emit.
Remarks
Call after all related tables exist (deferred FK phase). Prefer CreateForeignKeys when applying compare results.
string CreateForeignKeys(TableDifferences differences)
csharp
string CreateForeignKeys(TableDifferences differences)Generate SQL that applies foreign-key changes from a compare result (drops then adds). Returns null when there is no FK work.