December 29, 2010 at 10:41 pm
I have a simple link server accessing a mainframe DB2 database.
Select * from OpenQuery(DB2_SAMPLE,'Select * from Test1.Table1')
My doubt is whether this query will read uncommitted data or only committed data from DB2 ?
December 29, 2010 at 11:11 pm
This will solely rely on the way your DB2 environment and transactions are setup.
Normally it would only read committed transactions. If you DB2 tables and transactions are setup to not lock the row/page/table it is updating, you may end up with dirty reads, but it all depends.
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
This thing is addressing problems that dont exist. Its solution-ism at its worst. We are dumbing down machines that are inherently superior. - Gilfoyle
December 29, 2010 at 11:57 pm
Thanks for the reply ..
Does this mean that we cannot control the behaviour from SQL side .?
Is there something like with "no lock" hint which can be part of the query ..?
December 30, 2010 at 12:55 am
Does this mean that we cannot control the behaviour from SQL side .?
Is there something like with "no lock" hint which can be part of the query ..?
You can control the way you read from the source (DB2).
using WITH NO LOCK from SQL will merely read (if any) the data from the source, committed or uncommitted.
why would you want perform dirty reads anyway?
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
This thing is addressing problems that dont exist. Its solution-ism at its worst. We are dumbing down machines that are inherently superior. - Gilfoyle
December 30, 2010 at 1:56 am
This was removed by the editor as SPAM
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply