本文整理汇总了C#中System.Data.Common.DbConnection.Delete方法的典型用法代码示例。如果您正苦于以下问题:C# DbConnection.Delete方法的具体用法?C# DbConnection.Delete怎么用?C# DbConnection.Delete使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Data.Common.DbConnection
的用法示例。
在下文中一共展示了DbConnection.Delete方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Delete
public void Delete(int id)
{
using (_connection = Utilities.Database.GetProfiledOpenConnection())
{
_connection.Delete<TwitterApp>(id);
}
}
示例2: Delete
public void Delete(int id)
{
using (_connection = Utilities.GetProfiledOpenConnection())
{
_connection.Delete<Vote>(id);
}
}
示例3: Delete
public RestaurantType Delete(RestaurantType entity)
{
using (_connection = Utilities.GetProfiledOpenConnection())
{
_connection.Delete(entity);
}
return entity;
}
示例4: Delete
public Veto Delete(Veto entity)
{
using (_connection = Utilities.GetProfiledOpenConnection())
{
_connection.Delete(entity);
}
return entity;
}
示例5: Delete
public ActionResult Delete(int id)
{
using (_connection = Utilities.GetOpenConnection())
{
_connection.Delete<User>(id);
}
return RedirectToAction("index");
}
示例6: Delete
public Holiday Delete(Holiday entity)
{
using (_connection = Utilities.GetProfiledOpenConnection())
{
_connection.Delete(entity);
}
return entity;
}
示例7: Delete
public JobLog Delete(JobLog entity)
{
using (_connection = Utilities.GetProfiledOpenConnection())
{
_connection.Delete(entity);
}
return entity;
}
示例8: Delete
public ActionResult Delete(string id)
{
using (_connection = Utilities.GetOpenConnection())
{
_connection.Delete<GUIDTestViewModel>(id);
}
return RedirectToAction("index");
}