Skip to content

OleDbTransaction.Commit Exception ''SQLNCLI11' failed with no error message available #31177

Closed

Description

@Grauenwolf
  • netcoreapp2.1
  • System.Data.OleDB 4.6.0

Calling OleDbTransaction.Commit throws this exception:

System.Data.OleDb.OleDbException: ''SQLNCLI11' failed with no error message available, result code: E_NOINTERFACE(0x80004002).'

This does not occur when targeting net461.

If I execute the operations without a transaction they appear to work correctly.

Activity

  1. ArgusMagnus commented on Jan 15, 2020

    @ArgusMagnus

    I get the same exception with the JET provider:

    System.Data.OleDb.OleDbException (0x80004002): 'Microsoft.Jet.OLEDB.4.0' failed with no error message available, result code: E_NOINTERFACE(0x80004002)
    
  2. transferred this issue fromdotnet/corefxon Feb 1, 2020
  3. FreddyDgh commented on Feb 19, 2020

    @FreddyDgh
    Contributor

    I can confirm that transactions don't seem to working at all on .NET Core using the Microsoft.ACE.OLEDB.16.0 provider.

    Sample code:

            [TestMethod]
            public void TransactionCommitTest()
            {
                using (OleDbConnection conn = new OleDbConnection(CONN_STR))
                {
                    conn.Open();
    
                    OleDbTransaction transaction = conn.BeginTransaction();
    
                    transaction.Commit();
                    
                    conn.Close();
                }
            }
    
            [TestMethod]
            public void TransactionRollbackTest()
            {
                using (OleDbConnection conn = new OleDbConnection(CONN_STR))
                {
                    conn.Open();
    
                    OleDbTransaction transaction = conn.BeginTransaction();
    
                    transaction.Rollback();
    
                    conn.Close();
                }
            }

    Results:
    .NET Framework x86: PASS
    .NET Framework x64: PASS
    .NET Core x86: FAIL
    .NET Core x64: FAIL

    @saurabh500

  4. self-assigned this
    on Feb 19, 2020
  5. saurabh500 commented on Feb 19, 2020

    @saurabh500
    Contributor

    @FreddyD-GH thanks for posting the test case. This is the same issue that @jader1313 has reported. I will look into this.

  6. FreddyDgh commented on Feb 19, 2020

    @FreddyDgh
    Contributor

    Yes, just wanted to note that this one does NOT seem to be x86 specific.

  7. added
    untriaged
    on Feb 23, 2020
  8. removed
    untriaged
    on Jun 23, 2020
  9. ghost locked as resolved and limited conversation to collaborators on Dec 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions