Database Journal
MS SQL Oracle DB2 Access MySQL PostgreSQL Sybase PHP SQL Etc SQL Scripts & Samples Tips Database Forum Rss Feed

» Database Journal Home
» Database Articles
» Database Tutorials
MS Access
SQL Scripts & Samples
» Database Forum
» Slideshows
Free Newsletters:

News Via RSS Feed

Rss Feed

Database Journal |DBA Support |SQLCourse |SQLCourse2

Featured Database Articles


Posted Oct 4, 2003

Linked Servers on MS SQL: Part 1 - Page 2

By Don Schlichting

SQL to Excel

In our first example, we will link an Excel sheet to an MS SQL server. The Excel example is a one-sheet copy of the SQL Pubs table Authors.

Right-click to download the Excel Sheet

+ Open the SQL Enterprise Manager and navigate to Security/Linked Servers. Underneath, (No items) should be visible.

+ Right click the Linked Server icon and select New Linked Server.

+ Create a new linked server by entering any name in the Linked Server text box. Select "Other" as the data source, selecting the "Microsoft Jet 4" provider. The product is "Excel." The data source is the file path name. The Provider string is "Excel 8.0" for Excel versions 97, 2000, and 2002. Then click OK to finish.

Now in Enterprise Manager, under Linked Servers, the new "Excel_AUTHORS" server should appear with a table for each Excel Sheet.

To verify your connection, open SQL Query Analyzer and enter SELECT * FROM EXCEL_AUTHORS...Sheet1$. (3 dots between EXCEL_AUTHORS and Sheet1$) The author table should be returned.

MS SQL Archives

Latest Forum Threads
MS SQL Forum
Topic By Replies Updated
SQL 2005: SSIS: Error using SQL Server credentials poverty 3 August 17th, 07:43 AM
Need help changing table contents nkawtg 1 August 17th, 03:02 AM
SQL Server Memory confifuration bhosalenarayan 2 August 14th, 05:33 AM
SQL Server Primary Key and a Unique Key katty.jonh 2 July 25th, 10:36 AM