openrowset为什么会提示sqlserver不存在呢?
select a.* from openrowset( 'SQLOLEDB '
, '192.168.0.121 '; 'sa '; '12345 '
,master.dbo.sysobjects) as a
消息 17,级别 16,状态 1,第 1 行
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server 不存在或拒绝访问。
opensource也使这个错误?
是什么问题呢?
------解决方案--------------------你要打开的数据库服务器 服务启动了么?
------解决方案----------------------示例
USE pubs
GO
SELECT a.*
FROM OPENROWSET( 'SQLOLEDB ', 'seattle1 '; 'sa '; 'MyPass ',
'SELECT * FROM pubs.dbo.authors ORDER BY au_lname, au_fname ') AS a
GO
------解决方案----------------------try
select a.* from openrowset( 'SQLOLEDB '
, '192.168.0.121 '; 'sa '; '12345 '
, 'select * from master.dbo.sysobjects ') as a
------解决方案--------------------select a.* from openrowset( 'SQLOLEDB '
, '192.168.0.121 '; 'sa '; '12345 '
, 'select * from master.dbo.sysobjects ') as a
------解决方案--------------------select a.* from openrowset( 'SQLOLEDB '
, '192.168.0.121 '; 'sa '; '12345 '
,master.dbo.sysobjects) as a
-->
select a.* from openrowset( 'SQLOLEDB '
, '192.168.0.121 '; 'sa '; '12345 '
, 'select * from master.dbo.sysobjects ') as a