Solved

openRowSet returning " Could not create an instance of OLE DB provider 'SQLOLEDB'. "

Posted on 2004-04-13
6
817 Views
Last Modified: 2011-09-20
i am migrating a mssql7 db on nt4 to a mssql7 database on win2k.

on the new server there is an openrowset query returning " Could not create an instance of OLE DB provider 'SQLOLEDB'. "
     SELECT *
     FROM OPENROWSET ( 'SQLOLEDB', 'GROVER';'uid';'pswd', 'stored procedure' ) AS Hierarchy,
     FH_Media_Cat_213 AS Media_Ref WHERE Hierarchy.V_ID = 213 AND Hierarchy.H_ID = Media_Ref.Cat_ID

this query works fine on the old server, but for some reason doesn't on the new one.  i have added grover to the system odbc datasources with no change.

any ideas?
0
Comment
Question by:meyerc74
  • 2
  • 2
6 Comments
 
LVL 4

Accepted Solution

by:
BulZeyE earned 150 total points
ID: 10815689
Sounds like an issue with dlls and possibly versions.  Have you tried getting the latest MDAC from Microsoft ?

http://msdn.microsoft.com/data/downloads/updates/default.aspx
0
 
LVL 1

Author Comment

by:meyerc74
ID: 10815701
yes...installed mdav 2.8 prior to post
0
 
LVL 2

Assisted Solution

by:BoyPupa
BoyPupa earned 100 total points
ID: 10819739
You code says you're using sqloledb but you mention a dsn named GROVER.

Typically you would use sqloledb to establish a direct server connection without a DSN

eg:
 SELECT *
     FROM OPENROWSET ( 'SQLOLEDB', 'ServerName';testUser;'pswd', 'exec tempdb.dbo.sampleProc' )

to use a dsn it makes more sense to use msdasql odbc provider

eg:
SELECT *
FROM OPENROWSET('MSDASQL','DSN=sqlTest;UID=testUser;PWD=pswd;','exec sampleProc')
0
 
LVL 2

Expert Comment

by:BoyPupa
ID: 10819746
Sorry the sqloledb should read
 SELECT *
     FROM OPENROWSET ( 'SQLOLEDB', 'ServerName';'testUser';'pswd', 'exec tempdb.dbo.sampleProc' )
0
 
LVL 1

Author Comment

by:meyerc74
ID: 11547976
this actually ended up beinga versions issue
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I wrote this interesting script that really help me find jobs or procedures when working in a huge environment. I could I have written it as a Procedure but then I would have to have it on each machine or have a link to a server-related search that …
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties

896 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now