Please start any new threads on our new site at http://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 ODBC Connection from SQL Server Management Studio
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

durgapras
Starting Member

15 Posts

Posted - 03/05/2008 :  12:44:00  Show Profile  Reply with Quote
Hi,
I have created a DSN from the ODBC(Windows Control Panel) in Administrative tools.
Is there a way I can connect to that DB from my Microsoft SQL Server Management Studio?
PS:The Provider for this DB does not exist in LinkedServer

Thanks

durgapras
Starting Member

15 Posts

Posted - 03/05/2008 :  14:22:17  Show Profile  Reply with Quote
After little bit of 'googling',I could successfully connect to my ODBC

1.)Exec sp_addlinkedserver

EXEC sp_addlinkedserver

@server = 'MY_ODBC_SERVER',

@srvproduct = '',

@provider = 'MSDASQL',

@datasrc = 'QFTest' //System DSN

GO

2.)To check whether SP worked,

EXEC sp_tables_ex @table_server = 'MY_ODBC_SERVER'

3.)I could successfully retrieve all the data from the table 'BTL'

SELECT * FROM OPENQUERY(MY_ODBC_SERVER, 'SELECT * FROM BTL')
Go to Top of Page
  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000