Exemplo n.º 1
0
 public void CreateConstraint(TableInfo table, ConstraintInfo newcnt, PlanPosition pos = PlanPosition.End)
 {
     TableInfo tbl = Structure.FindOrCreateTable(table.FullName);
     AddOperation(new AlterOperation_CreateConstraint { ParentTable = tbl, NewObject = newcnt.CloneConstraint() }, pos);
 }
Exemplo n.º 2
0
 public void ChangeConstraint(ConstraintInfo constraint, ConstraintInfo newconstraint)
 {
     ConstraintInfo cnt = Structure.FindOrCreateConstraint(constraint);
     AddOperation(new AlterOperation_ChangeConstraint { OldObject = cnt, ParentTable = cnt.OwnerTable, NewObject = newconstraint.CloneConstraint() });
 }