Skip to content

Connection pool always creates a new connection #250

Open

Description

@beddead

The connection pool always creates a new connection if the connection string looks like the following:
b.UseJet(“Driver={Microsoft Access Driver (*.mdb, *.accdb)};extendedansisql=1;Jet OLEDB: Flush Transaction Timeout=0;dbq=” + dbPath);

This works if I enter the extended parameter in lower case. But then the JET engine ignores it.

Activity

  1. changed the title [-]Connection pooling always create new connections[/-] [+]Connection pool always creates a new connection[/+] on Jul 21, 2024
  2. ChrisJollyAU commented on Jul 21, 2024

    @ChrisJollyAU
    Member

    I don't think EFCore.Jet has full support for connection pooling yet. In fact the tests regarding that all fail (you only get a pool of 1).

    Also that connection string doesn't look right. Driver and DBQ are ODBC string settings. Then we have Jet OLEDB: Flush Transaction Timeout=0 which is for Ole DB. This part will obviously be excluded when using ODBC.

    Also just a note, we always set extendedansisql=1 for ODBC whether it is originally set or not

  3. beddead commented on Jul 21, 2024

    @beddead
    Author

    If I use

    b.UseJet(“Driver={Microsoft Access Driver (*.mdb, *.accdb)};dbq=” + dbPath);

    then pooling does not work too. Because it tries to find connection in pool dictionary using different connection string (with extendedansisql=1)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions