Subject | Re: Dirty Read |
---|---|
Author | andrew.pailthorpe@btinternet.com |
Post date | 2013-09-11T21:31:45Z |
Hi Set
Thanks for the reply.
To get a Dirty read I need to Create a new Connection to the Database and assign it a new Transaction ie:-
#region Create a new connection and Query Table
TFB_Connection TempConnection = new TFB_Connection (DBPath, Datasource, UserID, Password, Port);
FbTransaction trMyTransaction;
DataSet ds = new DataSet();
TempConnection.Connection.Open();
trMyTransaction = TempConnection.Connection.BeginTransaction(System.Data.IsolationLevel.ReadUncommitted);
using (FbCommand cmd = new FbCommand("SELECT * FROM EMPLOYEES TABLE WHERE ID = 26), TempConnection.Connection, trMyTransaction))
{
FbDataAdapter FbDataAdapter = new FbDataAdapter(cmd);
FbDataAdapter.Fill(ds);
}
This works.
Thanks for the reply.
To get a Dirty read I need to Create a new Connection to the Database and assign it a new Transaction ie:-
#region Create a new connection and Query Table
TFB_Connection TempConnection = new TFB_Connection (DBPath, Datasource, UserID, Password, Port);
FbTransaction trMyTransaction;
DataSet ds = new DataSet();
TempConnection.Connection.Open();
trMyTransaction = TempConnection.Connection.BeginTransaction(System.Data.IsolationLevel.ReadUncommitted);
using (FbCommand cmd = new FbCommand("SELECT * FROM EMPLOYEES TABLE WHERE ID = 26), TempConnection.Connection, trMyTransaction))
{
FbDataAdapter FbDataAdapter = new FbDataAdapter(cmd);
FbDataAdapter.Fill(ds);
}
This works.