List:General Discussion« Previous MessageNext Message »
From:Dan Nelson Date:October 31 2006 4:35pm
Subject:Re: MSSQL NoLock vs MySQL NoLock
View as plain text  
In the last episode (Oct 31), Ow Mun Heng said:
> Just wanted to post this here to see if anyone knows the difference.
> In MSSQL, there is a hint which can be used to ask the DB to not lock
> the tables during queries and then to read un-commited/dirty data.
> This command is like
> select count(*) from MyTable nolock
> in MySQL, I found that I can do the same thing with the same syntax.
> Having read through this post in the forum,
> I'm just curious to know if anyone knows that they are one and the same.

I don't see anything in that thread indicating that MySQL supports a
"nolock" keyword.  The 2nd post says to run a

  set transaction isolation level READ UNCOMMITTED;

statement before your query, which will put your session in a state
similar to MSSQL's nolock mode.

	Dan Nelson
MSSQL NoLock vs MySQL NoLockOw Mun Heng31 Oct
  • Re: MSSQL NoLock vs MySQL NoLockDan Nelson31 Oct
    • Re: MSSQL NoLock vs MySQL NoLockOw Mun Heng1 Nov