Esempio n. 1
0
        protected static int DeleteImpl <T>(T instance, DataSource ds, DataWhereQueue ps = null) where T : DbTable
        {
            DeleteBucket bucket = TDbTable <T> .GetDeleteSql(ds, instance, null, ps);

            return(ds.ExecuteNonQuery(ds.Provider.BuildDeleteSql(GetTableName <T>(), bucket.Wheres), bucket.Parameters));
        }
Esempio n. 2
0
        protected static int DeleteImpl <T>(T instance, DataSource ds, params DataColumn[] columns) where T : DbTable
        {
            DeleteBucket bucket = TDbTable <T> .GetDeleteSql(ds, instance, columns, null);

            return(ds.ExecuteNonQuery(ds.Provider.BuildDeleteSql(GetTableName <T>(), bucket.Wheres), bucket.Parameters));
        }