locked
Error :This OracleTransaction has completed; it is no longer usable. RRS feed

  • Question

  • User161781117 posted

    I get this error sometimes/ocassionally and dont know why?

    try

    {

    //initialize connection
    OracleConnection connection = new OracleConnection(ConnectionString);
    connection.Open();
    OracleCommand cmd = connection.CreateCommand();
    OracleTransaction trasaction;
    trasaction = connection.BeginTransaction(IsolationLevel.ReadCommitted);
    cmd.Transaction = trasaction;

    string SQL = "";

    cmd.CommandText = SQL;
    cmd.ExecuteNonQuery();

    {

    //do some more stuff

    }

    trasaction.Commit();

    }

    catch(Exception ex)

    {

     trasaction.Rollback();

    Wednesday, June 20, 2012 3:05 PM

All replies

  • User161781117 posted

    can someone please reply?

    Thursday, June 21, 2012 4:42 AM