Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8675807
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T20:02:09+00:00 2026-06-12T20:02:09+00:00

I have a data entry ASP.NET application. During a one complete data entry many

  • 0

I have a data entry ASP.NET application. During a one complete data entry many transactions occur. I would like to keep track of all those transactions so that if the user wants to abandon the data entry, all the transaction of which I have been keeping record can be rolled back.

SQL 2008 ,Framework version is 4.0 and I am using c#.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T20:02:10+00:00Added an answer on June 12, 2026 at 8:02 pm

    This is always a tough lesson to learn for people that are new to web development. But here it is:

    Each round trip web request is a separate, stand-alone thread of execution

    That means, simply put, each time you submit a page request (click a button, navigate to a new page, even refresh a page) then it can run on a different thread than the previous one. What’s more, even if you do get the same thread twice, several other web requests may have been processed by the thread in the time between your two requests.

    This makes it effectively impossible to span simple transactions across more than one web request.

    Here’s another concept that you should keep in mind:

    Transactions are intended for batch operations, not interactive operations.

    What this means is that transactions are meant to be short-lived, and to encompass several operations executing sequentially (or simultaneously) in which all operations are atomic, and intended to either all complete, or all fail. Transactions are not typically designed to be long-lived (meaning waiting for a user to decide on various actions interactively).

    Web apps are not desktop apps. They don’t function like them. You have to change your thinking when you do web apps. And the biggest lesson to learn, each request is a stand-alone unit of execution.

    Now, above, I said “simple transactions”, also known as lightweight or local transactions. There’s also what’s known as a Distributed Transaction, and to use those requires a Distributed Transaction Coordinator. MSDTC is pretty commonly used. However, DT’s perform much more slowly than LWT’s. Also, they require that the infrastructure be setup to use a DTC.

    It’s possible to span a transaction over web requests using a DTC. This is done by “Enlisting” in a Distribute Transaction, and then somehow sharing this transaction identifier between requests. But this is a lot of work to setup, and deal with, and has a lot of error prone situations. It’s not something you want to do if you have other options.

    In general, you’re better off adding the data to a temporary table or tables, and then when the final save is done, transfer that data to the permanent tables. Another option is to maintain some state (such as using ViewState or Session) to keep track of the changes.

    One popular way of doing this is to perform operations client-side using JavaScript and then submitting all the changes to the server when you are done. This is difficult to implement if you need to navigate to different pages, however.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got an asp.net application where each client will have their own data entry
I have a multi-step data entry form in my ASP.NET MVC application. When the
I have an ASP.NET web application for data entry, and we have big lists
I'm developing an ASP.NET form for data-entry. Users have to select a client from
Suppose that you have a big Data Entry Web Application Like Microsoft CRM ,
I have an ASP.Net MVC application. I am trying to post data to an
I have a forum like web application written in Asp.net MVC. I'm trying to
I have a standard data-entry type form built in ASP.NET. I am pretty green
A lot of lead up: I have a simple ASP .NET 3.5 data entry
I have two ASP.NET sites that are used for managing patient information. One application

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.