C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Reviews   Communities   Interview   Jobs   Projects   Training   Your Ad Here    
Silverlight Games | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Polls | Revenue Sharing | Lobby | Gift Shop |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...






Forums » .NET » SQL Server »

Storing Excel file into SQL Server database


Posted Date: 31 Dec 2008      Posted By: Saravanakumar      Member Level: Silver     Points: 1   Responses: 3



I need the code for storing Excel file into SQL Server Database. Any Third party control needs to store?




Responses

Author: Deepika Haridas    01 Jan 2009Member Level: DiamondRating: 2 out of 52 out of 5     Points: 2

Hi

Using sql server management studio simply you can import an Excel file in to the database that you want.

right click on the database -->tasks-->import data

and select Microsoft Excel as the datasource and specify the location....



Thanks & Regards,
Deepika
Editor

If U want to shine like a SUN..First U have to burn like the SUN!!
Need a Guide? Join my mentor program..



Author: Tejinder Singh Barnala    01 Jan 2009Member Level: GoldRating: 2 out of 52 out of 5     Points: 3

deepika is right, if you want to do it by GUI

if u want to do it through code
then

SELECT * INTO test2 FROM OPENROWSET('Microsoft.Jet.OLEDB.4.0',
'Excel 8.0;Database=d:\test.xls', 'SELECT * FROM [Sheet1$]')

/*d:\test.xls path of excel file
Sheet1 is name of sheet
test2 name of new table */

hope it will help you

Many Thanks
Tejinder Singh Barnala
/*I have the simplest tastes. I am always satisfied with the best*/



Author: www.DotNetVJ.com    02 Jan 2009Member Level: DiamondRating: 2 out of 52 out of 5     Points: 2

Hi
Check out the below link
http://chiragrdarji.wordpress.com/2007/08/31/storing-and-retrieving-docpdfxls-files-in-sql-server/

Thanks -- Vj
http://dotnetvj.blogspot.com

Thanks -- Vijaya Kadiyala
http://www.DotNetVJ.com
Microsoft MVP
Me & My Little Techie



Post Reply

 This thread is locked for new responses. Please post your comments and questions as a separate thread.
If required, refer to the URL of this page in your new post.


Next : Tejinder Singh Barnala
Previous : To Tejinder Singh Barnala-> Its Urgent
Return to Discussion Forum
Post New Message
Category: SQL Server

Related Messages



dotNet Slackers

About Us    Contact Us    Privacy Policy    Terms Of Use