摘要:
using (var uow = UnitOfWorkManager.Begin(TransactionScopeOption.RequiresNew)) { //所有数据库的操作 uow.Complete(); } 阅读全文
摘要:
//分批处理 int skip = 0; int takeSize = 1000; int totalCount = List.Count(); List<Task> taskList = new List<Task>(); while (skip < totalCount ) { var batc 阅读全文
摘要:
针对当前用户进行加锁 private readonly static Dictionary<long, object> dic = new Dictionary<long, object>(); 方法内部加入 object syncLocker = new object(); dic.TryGetV 阅读全文
摘要:
在接口方法上加上即可[DontWrapResult] 阅读全文
摘要:
--查看被锁表:--spid 锁表进程 --tableName 被锁表名 select request_session_id spid,OBJECT_NAME(resource_associated_entity_id) tableName from sys.dm_tran_locks where 阅读全文