Web Service 使用分布式事务出错(OLE DB provider 'SQLOLEDB'无法启动分布式事务)
2009-04-27 21:46
681 查看
环境: Windows XP SP2、 Sql Server 2000
问题描述:在搭建Web Service时,访问了远程数据库的Link Server(即应用服务器访问了两台数据库服务器),执行SQL语句,如下:
begin transaction
select CNCJ.dbo.Custmoer.TotalVol FROM CNCJ.dbo.Customer c1 left join OrderHeaderID o1 on c1.OrderID = o1.OrderID
WHERE or.CustomerProfileID = '188168' and o1.AggType = 'PPV' and o1.OrderMonth = '200805'
commit tran
go
CNCJ为数据库服务器上的Link Server。
出错:
The operation could not be performed because the OLE DB provider 'SQLOLEDB' was unable to begin a distributed transaction.
[OLE/DB provider returned message: New transaction cannot enlist in the specified transaction coordinator. ]
OLE DB error trace [OLE/DB Provider 'SQLOLEDB' ITransactionJoin::JoinTransaction returned 0x8004d00a].
解决办法:
1. 在数据库服务器上打开Sql Server的企业管理器,展开,右键“Local(Windows NT)”属性,确定“自动启动MSTDC”勾上。
2. 管理工具->组件服务->计算机->我的电脑,右键属性,MSTDC选项卡,点击按钮“Security Configuration..”,勾上Newwork DTC Access, Allow Remote Clients、Allow Remote Administration、Allow Inbound、Allow Outbound、No Authentication Required、Enable Transaction Internet Protocol(TIP) Transactions、Enable XA Transactions,Account:为NT AUTHORITY/Newwork Service
3. 管理工具->服务->找到Distributed Transaction Coordinator,双击,选择“Log on”选项卡,确保This account为NT AUTHORITY/Network Server。
问题描述:在搭建Web Service时,访问了远程数据库的Link Server(即应用服务器访问了两台数据库服务器),执行SQL语句,如下:
begin transaction
select CNCJ.dbo.Custmoer.TotalVol FROM CNCJ.dbo.Customer c1 left join OrderHeaderID o1 on c1.OrderID = o1.OrderID
WHERE or.CustomerProfileID = '188168' and o1.AggType = 'PPV' and o1.OrderMonth = '200805'
commit tran
go
CNCJ为数据库服务器上的Link Server。
出错:
The operation could not be performed because the OLE DB provider 'SQLOLEDB' was unable to begin a distributed transaction.
[OLE/DB provider returned message: New transaction cannot enlist in the specified transaction coordinator. ]
OLE DB error trace [OLE/DB Provider 'SQLOLEDB' ITransactionJoin::JoinTransaction returned 0x8004d00a].
解决办法:
1. 在数据库服务器上打开Sql Server的企业管理器,展开,右键“Local(Windows NT)”属性,确定“自动启动MSTDC”勾上。
2. 管理工具->组件服务->计算机->我的电脑,右键属性,MSTDC选项卡,点击按钮“Security Configuration..”,勾上Newwork DTC Access, Allow Remote Clients、Allow Remote Administration、Allow Inbound、Allow Outbound、No Authentication Required、Enable Transaction Internet Protocol(TIP) Transactions、Enable XA Transactions,Account:为NT AUTHORITY/Newwork Service
3. 管理工具->服务->找到Distributed Transaction Coordinator,双击,选择“Log on”选项卡,确保This account为NT AUTHORITY/Network Server。
相关文章推荐
- Web Service 使用分布式事务出错(OLE DB provider 'SQLOLEDB'无法启动分布式事务)
- 该操作未能执行,因为 OLE DB 提供程序 'SQLOLEDB' 无法启动分布式事务。新事务不能登记到指定的事务处理器中。
- SQL 错误 7391 因为 OLE DB 提供程序 'SQLOLEDB' 无法启动分布式服务
- msdtc服务无法在本地启动, 'SQLOLEDB' 无法启动分布式事务解决办法
- 链接服务器的 OLE DB 访问接口 "SQLNCLI" 无法启动分布式事务 外加SQL事务死锁问题
- 无法执行该操作,因为链接服务器 "......." 的 OLE DB 访问接口 "SQLNCLI" 无法启动分布式事务。
- 无法启动链接服务器 "........" 的 OLE DB 访问接口 "SQLNCLI10" 的嵌套事务。由于 XACT_ABORT 选项已设置为 OFF,因此必须使用嵌套事务。
- 无法执行该操作,因为链接服务器 "*****" 的 OLE DB 访问接口 "SQLNCLI " 无法启动分布式事务。
- 因为链接服务器 "SQLEHR" 的 OLE DB 访问接口 "SQLNCLI10" 无法启动分布式事务
- (win7)SQL SERVER 2005开发版 安装错误:无法找到产品Microsoft SQL Server Native Client的安装程序包,尝试再次使用的安装包 ' Sqlncli.ms
- 无法执行该操作,因为链接服务器 "xxxxx" 的 OLE DB 访问接口 "SQLNCLI" 无法启动分布式事务
- 一个关于“OLE DB 提供程序 'sqloledb' 指出该对象中没有任何列”错误的解决方法
- 因为链接服务器 "SQLEHR" 的 OLE DB 访问接口 "SQLNCLI10" 无法启动分布式事务
- 无法执行该操作,因为链接服务器 "xxxxx" 的 OLE DB 访问接口 "SQLNCLI" 无法启动分布式事务。
- 解决windows 2003+Sql2000中OLEDB分布式事务无法启动的解决方案
- Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: 数据库 'BHIoTV1.1' 的事务日志已满。若要查明无法重用日志中的空间的原
- 解决windows 2003+Sql2000中OLEDB分布式事务无法启动的解决方案
- 解决windows 2003+Sql2000中OLEDB分布式事务无法启动的解决方案
- 一个关于“OLE DB 提供程序 'sqloledb' 指出该对象中没有任何列”错误的解决方法
- 无法执行该操作,因为链接服务器 "xxxxx" 的 OLE DB 访问接口 "SQLNCLI" 无法启动分布式事务 .