Skip to content

Implement parallel support for ODBC and OLE DB #45

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
lauxjpn opened this issue Mar 27, 2020 · 9 comments · Fixed by #74
Closed

Implement parallel support for ODBC and OLE DB #45

lauxjpn opened this issue Mar 27, 2020 · 9 comments · Fixed by #74
Assignees
Milestone

Comments

@lauxjpn
Copy link
Member

lauxjpn commented Mar 27, 2020

Continues the discussion around this feature from #43.

@lauxjpn lauxjpn added this to the 3.1.x milestone Mar 27, 2020
@lauxjpn lauxjpn self-assigned this Mar 27, 2020
@lauxjpn
Copy link
Member Author

lauxjpn commented Mar 27, 2020

For all advanced statements (like CREATE VIEW or CREATE PROCEDURE) to work with ODBC, ExtendedAnsiSQL=1 has do be added to the connection string (see Using the ExtendedAnsiSQL Connection String Attribute (Access Driver) for further details).

We should do this implicitly in EFCore.Jet, so that nobody has to worry about it. In case anybody complains about it in the future for some reason, we can always add an option to disable it.

I also had to switch the identifier character from [identifier] (square brackets) to `identifier` (backticks) because ODBC complaint about the square brackets when used for the newly supported ODBC 4.0 statements (like CREATE VIEW). The backtick is the official identifier character for ODBC and works for OLE DB and in Access as well.

@lauxjpn
Copy link
Member Author

lauxjpn commented Mar 28, 2020

I am going to add support for automatic provider/driver detection, so that just specifying a database name will use the newest installed database provider/driver.

We can get rid of JetConfiguration.OleDbDefaultProvider and JetConfiguration.OdbcDefaultProvider with that.

@lauxjpn
Copy link
Member Author

lauxjpn commented Mar 28, 2020

In the future, we should consider refactoring the ODBC/OLE DB conditionals into their own self-contained classes, and ship them as EntityFrameworkCore.Jet.Odbc and EntityFrameworkCore.Jet.OleDb, that could then be discovered by EntityFrameworkCore.Jet at runtime.

@lauxjpn
Copy link
Member Author

lauxjpn commented Mar 29, 2020

For all advanced statements (like CREATE VIEW or CREATE PROCEDURE) to work with ODBC, ExtendedAnsiSQL=1 has do be added to the connection string (see Using the ExtendedAnsiSQL Connection String Attribute (Access Driver) for further details).

We should do this implicitly in EFCore.Jet, so that nobody has to worry about it. In case anybody complains about it in the future for some reason, we can always add an option to disable it.

Implemented in bdfbafa of #47.

@bubibubi
Copy link
Member

I looked at the code. There are still square brackets around (at least in RemoveBrackets method). Probably we could just find [ and replace (or, better, cover with tests because as far as I can understand all the tests work fine now).

@lauxjpn
Copy link
Member Author

lauxjpn commented Mar 29, 2020

I looked at the code. There are still square brackets around (at least in RemoveBrackets method).

Thanks, I missed a couple of those! I checked the EFCore.Jet and System.Data.Jet projects and fixed the remaining occurrences (see 6141f1e of #47).

because as far as I can understand all the tests work fine now

They should all be running, but we are far away from having all the test green.

@bubibubi
Copy link
Member

@lauxjpn WHAT A HUGE WORK!!! Great!!!

@bubibubi
Copy link
Member

They should all be running, but we are far away from having all the test green.

When you think that everything is stable enough tell me something because I'd like to help you on test fixing.

@lauxjpn
Copy link
Member Author

lauxjpn commented Mar 29, 2020

The code should be stable enough after merging #47 (which I am going to do in a couple of hours). We currently have 1110 green, 788 red and 100 skipped tests from the SimpleQueryJetTest tests.

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

Successfully merging a pull request may close this issue.

2 participants