title: Getting an invalid number error at random
body: <p>I am using the following code with an Oracle ADO.Net provider (DevArt's <a href="http://www.devart.com/dotconnect/universal/" rel="nofollow">dotConnect Universal</a>). Funny thing is that it works sometimes and then most times it throws <code>Devart.Data.Oracle.OracleException: ORA-01722: invalid number</code></p>
  
  <pre><code>  string sql = "SELECT DISTINCT  B.PRICE_TIER_KEY,b.label, a.INSERT_DATE   AS PriceEffectiveDate,B.PROGRAM_KEY AS PRICE_PROGRAM_KEY FROM GHX_MEMBER_TIER A INNER JOIN VHA_INT_PRICE_TIER B ON A.SRC_ID_VALUE = B.PRICE_TIER_KEY WHERE RowNum &lt;=100";
  
          DbProviderFactory dpf = DbProviderFactories.GetFactory(System.Configuration.ConfigurationManager.ConnectionStrings["Con_ORA_DevArt"].ProviderName);
          DbConnection conn = dpf.CreateConnection();
          conn.ConnectionString = System.Configuration.ConfigurationManager.ConnectionStrings["Con_ORA_DevArt"].ConnectionString;
  
          DbCommand dbcmd = dpf.CreateCommand();
          dbcmd.Connection = conn;
          //dbcmd.Connection = uniConnection1;
          dbcmd.CommandText = sql;
          dbcmd.CommandType = CommandType.Text;
          dbcmd.CommandTimeout = 0;
  
  
          DataTable table = new DataTable();
  
  
  
          try
          {
              System.Data.Common.DbDataAdapter da = dpf.CreateDataAdapter();
              da.SelectCommand = dbcmd;
              // Fill the DataTable.
  
              da.Fill(table);
          }
          catch (Exception ex)
          {
              throw;
          }
          finally
          {
              if (conn != null &amp;&amp; conn.State != ConnectionState.Closed)
              {
                  conn.Close();
                  conn.Dispose();
              }
              if (dbcmd != null)
              {
                  dbcmd.Dispose();
              }
          }
  </code></pre>