Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. Database
  4. SQL Server and ADO.net IsolationLevel

SQL Server and ADO.net IsolationLevel

Scheduled Pinned Locked Moved Database
csharpdatabasesql-servervisual-studiocom
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Online
    P Online
    PIEBALDconsult
    wrote on last edited by
    #1

    I'm experimenting with having multiple threads performing INSERTs into a table (no SELECTs, UPDATEs, or DELETEs) and I'm curious how the various IsolationLevels[^] affect performance. I have tried a few and seen no big differences. The documentation and what other information I have seen online (including here) has always seemed pretty vague to me -- and really only talks about reads (which aren't pertinent in this case). Anyone have any insight on how IsolationLevel affects INSERTs?

    You'll never get very far if all you do is follow instructions.

    L 1 Reply Last reply
    0
    • P PIEBALDconsult

      I'm experimenting with having multiple threads performing INSERTs into a table (no SELECTs, UPDATEs, or DELETEs) and I'm curious how the various IsolationLevels[^] affect performance. I have tried a few and seen no big differences. The documentation and what other information I have seen online (including here) has always seemed pretty vague to me -- and really only talks about reads (which aren't pertinent in this case). Anyone have any insight on how IsolationLevel affects INSERTs?

      You'll never get very far if all you do is follow instructions.

      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      PIEBALDconsult wrote:

      and really only talks about reads

      Because that's what could give trouble; if thread 1 does an partial update on a table, while thread 2 is reading that table - do you want the old or the new values in your result for thread 2? I don't see any problems when multiple threads insert data. That is, if they are values - if you are reading within that insert-statement (a select, like say, the count of this table), then you might have above problem again.

      Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^]

      P 1 Reply Last reply
      0
      • L Lost User

        PIEBALDconsult wrote:

        and really only talks about reads

        Because that's what could give trouble; if thread 1 does an partial update on a table, while thread 2 is reading that table - do you want the old or the new values in your result for thread 2? I don't see any problems when multiple threads insert data. That is, if they are values - if you are reading within that insert-statement (a select, like say, the count of this table), then you might have above problem again.

        Bastard Programmer from Hell :suss: If you can't read my code, try converting it here[^]

        P Online
        P Online
        PIEBALDconsult
        wrote on last edited by
        #3

        Eddy Vluggen wrote:

        if they are values

        Right, just simple insertion of values, no reading.

        You'll never get very far if all you do is follow instructions.

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups