title: Set Isolation level to DIRTY READ in Entity Framework with Informix
body: <p>Is there a way to set isolation levels in Entity Framework 5 with Informix database or LOCK MODE TO WAIT?</p>
  
  <p>I have tried to set isolation using SQL query, at the time of DbContext object creation.      </p>
  
  <pre><code>var dataContext = new DatabaseNameContext();  
  dataContext.Database.ExecuteSqlCommand("SET ISOLATION TO DIRTY READ");
  </code></pre>
  
  <p>But it seems this is not working. I am still getting a lock exception: </p>
  
  <pre><code>IBM.Data.DB2.DB2Exception (0x80004005): ERROR [IX000] [IBM][IDS/UNIX64]
  Could not do a physical-order read to fetch next row.
  (-107 ISAM error: record is locked.
  </code></pre>
  
  <p>I tried using TransactionScope with System.Transactions.IsolationLevel.ReadUncommitted, but it is throwing the exception:  </p>
  
  <pre><code>IBM.Data.DB2.DB2Exception (0x80004005): ERROR [58005] [IBM][IDS/UNIX64]
  SQL0998N Error occurred during transaction or heuristic processing.
  Reason Code = "16". Subcode = "2-8004D026".
  </code></pre>
  
  <p>Can you explain what's going wrong and how to fix it?</p>