473,385 Members | 1,655 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

ReadCommitted

Hi,

For IsolationLevel.ReadCommitted, here "Committed" does not mean
trans.Commit(), it just means db has been updated. -- Is this right?

It means other thread/connection can read "my" data before I finish a
transaction.

Please clarify this.

Thanks a million1
R L
Jun 25 '07 #1
1 2235
No; "committed" means "committed":

<quote>READ COMMITTED
Specifies that statements cannot read data that has been modified but
not committed by other transactions. This prevents dirty reads. Data
can be changed by other transactions between individual statements
within the current transaction, resulting in nonrepeatable reads or
phantom data. This option is the SQL Server default.

The behavior of READ COMMITTED depends on the setting of the
READ_COMMITTED_SNAPSHOT database option:

If READ_COMMITTED_SNAPSHOT is set to OFF (the default), the Database
Engine uses shared locks to prevent other transactions from modifying
rows while the current transaction is running a read operation. The
shared locks also block the statement from reading rows modified by
other transactions until the other transaction is completed. The
shared locks are released when the statement completes.

If READ_COMMITTED_SNAPSHOT is set to ON, the Database Engine uses row
versioning to present each statement with a transactionally consistent
snapshot of the data as it existed at the start of the statement.
Locks are not used to protect the data from updates by other
transactions.

When the READ_COMMITTED_SNAPSHOT database option is ON, you can use
the READCOMMITTEDLOCK table hint to request shared locking instead of
row versioning for individual statements in transactions running at
the READ_COMMITTED isolation level.</quote>

Marc

Jun 25 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: mahajan.sanjeev | last post by:
I have two SQLConnection objects having the same connection string and two corresponding SQLCommand objects for each connection object. I am using SQLTransaction with the first SQLConnection object...
2
by: mahajan.sanjeev | last post by:
Hi, I am having problems with rollback using the SQLTransaction object. I am trying to insert records in two tables in a transaction. I want to rollback all the changes if any exception occurs...
0
by: Dinu | last post by:
Hi All I am trying to insert data within a transaction, into a Db2 database from asp.net. I have created a System DSN using ISeries Access Driver(32 bit) for Windows. I am then connecting...
3
by: Mike P | last post by:
I am using transactions on my website and the Isolation Level is ReadCommitted. Since the website has a lot of traffic this may be causing it to lock up every now and again. Can somebody tell...
0
by: Newbie | last post by:
I'm getting the exception: ORA-01453: SET TRANSACTION must be first statement of transaction According to the information on the web, I have to Commit( ) before my set statement. But it didnt fix...
1
by: sansaw80 | last post by:
Hello Everyone, I got flexgrid with around 500 rows and 24 columns which gets populated using data from various tables. User can change any cell values at anytime. I want to save those values in...
4
by: majo | last post by:
Hi, I had posted this once earlier, but couldnt get my problem solved. When i run an asp.net application in windows 2003 server with IIS 6.0, it "SOMETIMES" gives me the below given error....
0
by: eric.goforth | last post by:
Hello, I have a subroutine similar to the following: Private Sub RunUpdateTransaction(ByVal UpdateSQL As String, ByVal UpdateConn As SqlConnection) Dim trnDedupe As SqlTransaction =...
3
by: D. | last post by:
I have a question about the "readCommitted" transaction isolation level. I have a client that is updating a record on a table. I suspend the execution after the UPDATE but before the commit...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.