0

I'm using sql server 2008. I have a database "CustomerManagement", and a table "Customer" like this:

CustomerID    |    Name    |    Money
1             | Paul       | 300
2             | Mary       | 250
3             | David      | 
4             | May        | 
5             | Ann        | 

And I have an excel file, with some data as the following:

CustomerID    |    Money
3             | 100
4             | 150
5             | 175

How I can insert "Money" in excel file to sql server based on CustomerID?

I'm using winform C# and MS Excel 2010

2
  • did you search SO or google? stackoverflow.com/questions/10750803/… Commented Nov 26, 2012 at 8:10
  • @Asken: yes, i did. But it tutorials insert data from excel to a new table. What I want is insert data to table with specified ID Commented Nov 26, 2012 at 8:15

1 Answer 1

1

Retrieve all the data from Excel which you want to insert to sql Database and then loop it and insert to sql server.

Retrieve Data

Insert to SQL Database

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.