protected void DropTableReferences(ITableStructure table, DropFlags flags) { bool refs = (flags & DropFlags.DropReferences) != 0; if (refs) { this.DropConstraints(table.GetReferencedFrom(), flags); } }
public void Save(XmlElement xml) { this.SavePropertiesCore(xml); new TableStructure(m_table).Save(xml.AddChild("Structure")); foreach (var fk in m_table.GetReferencedFrom()) { var x = xml.AddChild("Reference"); fk.Table.FullName.SaveToXml(x); new ForeignKey(fk).Save(x); } }
public SelectReferenceForm(ITableStructure table, string activeColumn, List <string> availcols, ISqlDialect dialect) { InitializeComponent(); m_table = table; m_dialect = dialect; m_availcols = availcols; FillList(lsvDetailReferences, m_table.GetReferencedFrom(), null, AcceptDetail); FillList(lsvMasterReferences, m_table.GetConstraints <IForeignKey>(), activeColumn, AcceptMaster); tbxBaseTable.Text = table.ToString(); }