[ODBC-323] Selects wrong unique index when accessing table data from MSAccess Created: 2021-06-15 Updated: 2022-09-26 Resolved: 2022-09-26 |
|
| Status: | Closed |
| Project: | MariaDB Connector/ODBC |
| Component/s: | General |
| Affects Version/s: | 3.1.11 |
| Fix Version/s: | 3.1.16 |
| Type: | Bug | Priority: | Major |
| Reporter: | Walter van der Geest | Assignee: | Lawrin Novitsky |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Windows 10, MariaDB Server 10.5 |
||
| Description |
|
When linking from MSAccess to a table on MariaDB which has a primary key and a second unique key on a field which allows NULL values, the key with the alphabetically lower name is selected. This results into wrong displayed records in MSAccess table view. Details:
It WANTS to have an absolute unique field name in order to retrieve the correct record, but it does not consider that UNIQUE Indexes in MariaDB can contain NULL values (multiple times), only the NON-NULL values have to be unique. This results in e.g. MSAccess table view to multiple Queries like 'SELECT * FROM myTab WHERE a_unique_id IS NULL', which returns more than one row, but only the first is displayed. So, has a table this format and entries:
In Access the table view shows the records:
|
| Comments |
| Comment by Walter van der Geest [ 2022-09-24 ] |
|
Same as |
| Comment by Lawrin Novitsky [ 2022-09-26 ] |
|
Thank you for the high quality report, and sorry - I'd got it off my radar, it could save some time on problem investigation. I am closing this issue as a duplicate, since you do not say that the problem is still present. |