forum.venkateswarlu.net
      Register      Login
Export Excel file to sql server without coding......

2 replies to this topic

Aisha Bobby #1
Member
96 Points
Posted on 02 Sep 2013 05:47 PM IST

Hai,

I have strucked in work, which i am going to get the data from the excel sheet and insert it into SQL Server 2005/2008 database. How can i do it? can any one help me out to get me out of this problem. Without any coding.

Regards,
Aisha

 
Other     830 views     Reply to this topic
Jahnavi N #2
Member
164 Points
Replied on 03 Sep 2013 06:45 AM IST

SELECT * INTO Your_Table_Name

FROM OPENROWSET('Microsoft.Jet.OLEDB.4.0',

'Excel 8.0;Database=C:\Folder\MyFile.xls',yes"> 'SELECT * FROM [Sheet1$]')

 
Reply to this topic
Subramaniam R #3
Member
152 Points
Replied on 03 Sep 2013 10:34 AM IST

exec sp_configure 'show advanced options', 1
RECONFIGURE;
exec sp_configure 'Ad Hoc Distributed Queries', 1
RECONFIGURE;


SELECT * FROM OPENROWSET('Microsoft.Jet.OLEDB.4.0',
'Excel 8.0;Database=C:\Users\Admin\Desktop\247ProjectMonitoring\UploadExcelfile\Test.xls;HDR=YES;IMEX=1;', 'SELECT * FROM [Sheet1$]')

 
Reply to this topic