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

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Querying Excel File

Author  Topic 

erickwidya
Starting Member

5 Posts

Posted - 2007-08-16 : 00:13:27
scenario:

it's for client - server application..the application need to querying an excel file than insert it into MSSQLServer2005

the problem is..when i develop the program, i create linked server and the querying is fine coz it use local server

the problem when the application move to Client - Server environment..
at the client side there's not MSSQL Server installed just the connection tools and because of that the LinkedServer can not worked anymore..

is there any solutin for this one?

PS: not sure where to put this post..sorry if i post it in wrong forum

thanks,
erick

shallu1_gupta
Constraint Violating Yak Guru

394 Posts

Posted - 2007-08-16 : 01:35:07
Hi,
you can use Opendatasource method to query data from Excel file...
SELECT *
FROM
OPENDATASOURCE('Microsoft.Jet.OLEDB.4.0', 'Data Source=C:\file.xls;
Extended Properties=''Excel 8.0''')...[Sheet1$]
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-08-16 : 02:06:45
http://sqlteam.com/forums/topic.asp?TOPIC_ID=49926

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page
   

- Advertisement -