?
Solved

Linq to sql , insert statements inside transcations

Posted on 2010-09-08
4
Medium Priority
?
345 Views
Last Modified: 2013-11-11
I need to perform the following 2 tasks
1) insert into transactionheader
2) insert into transactiondetail

How can I do this using Linq to sql, and inside a transaction block. any suggestions or links to other urls wold be rgeatly appreciated. thanks a ton. I am using .net 4.0
0
Comment
Question by:TrialUser
[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
4 Comments
 
LVL 5

Accepted Solution

by:
roxviper earned 668 total points
ID: 33626362
Hi,

Please check out this link:

http://www.west-wind.com/weblog/posts/826145.aspx
0
 
LVL 5

Assisted Solution

by:Vipul Patel
Vipul Patel earned 668 total points
ID: 33626367
Below url might be help you to resolve your problem

http://stackoverflow.com/questions/755796/how-to-create-a-linq-to-sql-transaction
0
 
LVL 18

Assisted Solution

by:Anil Golamari
Anil Golamari earned 664 total points
ID: 33627259
Dim q = From s In db.statements _
            Where s.ID = "some ID" _
            Select s

       Dim newStatement = New Statement With {.StatementID = "1", .CompanyName = "", .statement = "somedescription", .statementHeader = "header"}
    db.statements .Add(newStatement )
    db.SubmitChanges()

try something like this.
0
 

Author Closing Comment

by:TrialUser
ID: 33746209
thanks
0

Featured Post

What is a Denial of Service (DoS)?

A DoS is a malicious attempt to prevent the normal operation of a computer system. You may frequently see the terms 'DDoS' (Distributed Denial of Service) and 'DoS' used interchangeably, but there are some subtle differences.

Question has a verified solution.

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

This article describes relatively difficult and non-obvious issues that are likely to arise when creating COM class in Visual Studio and deploying it by professional MSI-authoring tools. It is assumed that the reader is already familiar with the cla…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.
Suggested Courses

762 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