TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
User77
NA
52
27.6k
same columns for different tables using sqlbulkcopy
Oct 27 2016 9:25 AM
Hi in my web application, I have 4 Data base tables and 3 tables are have same column names and how can i take in sqlbulkcopy method. Can anyone please tell me
objbulk.DestinationTableName = "Adjustments";
objbulk.DestinationTableName = "Payments";
objbulk.DestinationTableName = "Charges";
objbulk.ColumnMappings.Add("ID", "ID");
objbulk.ColumnMappings.Add("Description", "Description");
objbulk.ColumnMappings.Add("Credits", "Credits");
objbulk.ColumnMappings.Add("QTY%", "QTYInPercentage");
objbulk.ColumnMappings.Add("Amount", "Amount");
objbulk.ColumnMappings.Add("Amount %", "AmountInPercentage");
objbulk.ColumnMappings.Add("Client", "Client");
con.Open();
objbulk.WriteToServer(dt);
con.Close();
Thank you
Reply
Answers (
1
)
Export PDF then send PDF attachment to email
Convert utf-8 text file to PDF