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

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 vab to insert excel into sql table
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

maba1
Starting Member

1 Posts

Posted - 08/16/2013 :  16:40:07  Show Profile  Reply with Quote
I need very simple vba code that will insert excel data into a sql table

The sql server is 2005
The server name is myserver
The database is mydatabase


The excel spreadsheet has the field names in row 1 followed by rows of data. I think i can use an ado connection but but haven't been able to figure it out. The excel data will always be in columns A through E on sheet1, but the number of rows will vary. I don't need the macro to check or validate data anything or handle errors

I only ask that you please don't offer alternate ways. The user will be in excel, enter data and run macro.

Desparate and frustrated don't begin to tell you how i'm feeling. All the examples I reserched takes you from SQL into Excel. I'm sure there's a good reasdon for this, but this is the method I have to use.






  Previous Topic Topic Next Topic  
 New 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.09 seconds. Powered By: Snitz Forums 2000