惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Hugging Face - Blog
Hugging Face - Blog
云风的 BLOG
云风的 BLOG
Google DeepMind News
Google DeepMind News
美团技术团队
J
Java Code Geeks
V
V2EX
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
The Cloudflare Blog
宝玉的分享
宝玉的分享
博客园 - Franky
Y
Y Combinator Blog
爱范儿
爱范儿
H
Help Net Security
腾讯CDC
G
Google Developers Blog
B
Blog RSS Feed
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
阮一峰的网络日志
阮一峰的网络日志
罗磊的独立博客
V
Visual Studio Blog
The GitHub Blog
The GitHub Blog
博客园_首页
C
Check Point Blog
博客园 - 三生石上(FineUI控件)

博客园 - ccczqh

Entity Framework对NULL值的处理 整理一下Entity Framework的查询 SqlHelper 类实现详细信息 SQL Server 2008R2中增加了新的智能 DateTime 数字型 C# tostring()汇总 DataGridView 列宽和行高自动调整的设定 datagridview,第一列前没有灰的一列 DataGridView取消默认选中行 dataGridView空白列,默认选中行的背景色,dataGridView中加入复选框勾选状态的更改 C# winform DataGridView 常见属性 C# dataGridView上下移动选中行 转ADO.NET Entity Framework 入门示例向导(附Demo程序下载) c#加密解密 大数据类型通过存储过程保存数据(clob,blob) WinForm 下实现一个自动关闭的MessageBox C#简单游戏外挂制作(以Warcraft Ⅲ为例) [WebBrowser][Cookie] Document.Cookie 取得的Cookies不完整問題 C# DllImport的用法
sqlhelper 使用事务实例
ccczqh · 2013-02-17 · via 博客园 - ccczqh

string myConnectString = "Persist Security Info=False;Integrated Security=SSPI;database=northwind;server=mySQLServer;Connect Timeout=30";

SqlConnection myConnection = new SqlConnection(myConnectString);
myConnection.Open();
SqlTransaction st = myConnection .BeginTransaction();
try
{
...
SqlHelper.ExecuteDataset(st,...);
SqlHelper.ExecuteDataset(st,...);
...
st.Commit();
}
catch(SqlException ee)
{
st.Rollback();
throw ee;
}