コード例 #1
0
        private void button_CreaTabella_Click(object sender, EventArgs e)
        {
            adb.Connection("nuovodb.mdf");

            adb.AddTable(new ADB_TableModel(
                             name: "citta",
                             record: new string[] { "id int", "nome varchar(50)", "abitanti int" },
                             primarykey: "id",
                             primarykeyIdentity: true
                             ));

            adb.AddTable(new ADB_TableModel(
                             name: "studenti",
                             record: new string[] {
                "id int",
                "nome varchar(30)",
                "cognome varchar(30)",
                "idcitta int"
            },
                             primarykey: "id",
                             primarykeyIdentity: true,
                             foreignkey: new string[, ] {
                { "idcitta", "citta(id)" }
            }
                             ));
            MessageBox.Show("Tabella creata");

            adb.AddTable("test", "id INT IDENTITY(1,1) NOT NULL PRIMARY KEY, prova VARCHAR(30)");
            MessageBox.Show("Tabella test creata");
        }
コード例 #2
0
 private void OttieniInformazioni_Load(object sender, EventArgs e)
 {
     adb.Connection("nuovodb.mdf");
 }
コード例 #3
0
 private void VisteProcedure_Load(object sender, EventArgs e)
 {
     adb.Connection("nuovodb.mdf");
 }
コード例 #4
0
 private void GestisciDati_Load(object sender, EventArgs e)
 {
     adb.Connection("nuovodb.mdf");
 }
コード例 #5
0
 private void TestVari_Load(object sender, EventArgs e)
 {
     adb.Connection("Campionato.mdf");
 }
コード例 #6
0
 private void ManipolaColonne_Load(object sender, EventArgs e)
 {
     adb.Connection("nuovodb.mdf");
 }