Basic ASP.Net database interaction question

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Monroeski
    New Member
    • Aug 2007
    • 30

    Basic ASP.Net database interaction question

    We have an MS Access database that we are using at my work. Currently, everything is done through forms in Access, but this makes making any updates to the forms difficult, as there is always somebody in the file so we can never save any changes. The plan is to make the forms web based. We're currently looking at a few different options - the first is to use Infopath, which a coworker is learning right now, while the other is to use ASP.Net.

    I'm really not a fan of Infopath at all, as it has always felt a little too restrictive to me, so I'd prefer to use ASP.Net. My main concerns with that have to do with maintaining data integrity. Basically, we will have a page that, when the user selects a service name, will display all the hiring actions for that service. We would face the basic problem of two people having the same service open and making changes to it, thus having one of them over-writing the other person's changes. Nobody on the team is all that intimately familiar with ASP, so I'm worried that the workaround for this is going to take a lot more knowledge of the language than we currently have or could learn in a short amount of time.

    I guess the real question I have is how does record locking work in ASP.Net? If I run a query for, say, all the hiring actions where service = fiscal, does it only lock down the Fiscal records, or does it lock the whole table?
  • Plater
    Recognized Expert Expert
    • Apr 2007
    • 7872

    #2
    I am not sure ANYTHING gets locked down. I've not come accross anything getting locked in usage, unfortunatly.

    Comment

    • Monroeski
      New Member
      • Aug 2007
      • 30

      #3
      Originally posted by Plater
      I am not sure ANYTHING gets locked down. I've not come accross anything getting locked in usage, unfortunatly.
      So, basically, ensuring integrity of data if more than one person is in there is either impossible or would require a bunch of complex code of some sort?

      Comment

      • Plater
        Recognized Expert Expert
        • Apr 2007
        • 7872

        #4
        Originally posted by Monroeski
        So, basically, ensuring integrity of data if more than one person is in there is either impossible or would require a bunch of complex code of some sort?
        Well, I cann't make that statement for sure, I hope someone who can will chime in on this.

        I believe databases themselves have some sort of self-locking behavior (I believe sql server does internally).

        I would think adding a "Last Modified" column to every table would be a quick and dirty way to handle this.
        Consider:
        Two users each load the same record from a table. Each one gets a last modified value of say "2/25/2008 9:00:32 AM".
        One user saves the record back, which updates the record to be "2/25/2008 9:04:48 AM".
        When the 2nd user goes to save the record back, they get notified that last modified date in the record does not much the one it was when they loaded the record.

        Where you go from there, I'm not sure, but I think this is roughly how wiki software does it (minus all the changelog history stuff)

        Comment

        Working...