Solved

how to insert records from datatable to sql database using visual studio 2012

Posted on 2014-02-18
3
565 Views
Last Modified: 2014-02-18
how to insert records from datatable to sql database using visual studio 2012?
0
Comment
Question by:Meinhoonaa
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 65

Expert Comment

by:Jim Horn
ID: 39867950
>insert records from datatable to sql database
Q1:  Why does this have to be done with Visual Studio, and which application in Visual Studio are we talking?
Q2:  Are these databases on the same server?
  If yes, You can create a Stored Procedure that does this, referencing both databases, and execute it.  Then the SP can be called from wherever.
  If no, then you'll need an ETL tool such as SSIS, which is part of the Visual Studio suite, to move the data.
0
 

Author Comment

by:Meinhoonaa
ID: 39867967
I am using sql data client
0
 
LVL 33

Accepted Solution

by:
Big Monty earned 500 total points
ID: 39868108
here's a good tutorial that'll walk you through the steps on doing this:

http://www.codeproject.com/Articles/30722/How-to-save-data-from-a-DataSet-into-a-T-SQL-table
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
This article shows gives you an overview on SQL Server 2016 row level security. You will also get to know the usages of row-level-security and how it works
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question