KDb/Drivers/ODBC
We use "ODBC Driver" term in these papers, although it is all about developing KexiDB-level driver that is built on top of existing lower-level ODBC libraries. So by ODBC Driver we don't mean developing the layer between given database and ODBC protocols.
Old wiki page: [1] (TODO: migrate here)
There was old unused code in kexidb/drivers/odbs/ directory in Kexi 0.x, quickly disabled, and removed in Sep 2014 in Kexi 2.9.
Status: Experimental, not published, volunteers needed
Terms
We use "ODBC Driver" term in these papers, although it is all about developing KexiDB-level driver that is built on top of existing lower-level ODBC libraries, as described below. So, by ODBC Driver we don't mean developing the layer between given database and ODBC protocols.
Main Issues
There are a few different apporaches for ODBC implementation:
- On UNIX, there are unixODBC and iODBC projects.
- On win32, shipped with the OS
- On macOS Apple bundles iODBC with the OS
- We need to decide which one (unixODBC or iODBC) to use on UNIX. Using iODBC could simplify later intergation on macOS.
Motivation for developing the ODBC driver for both targets:
- For better promotion of migration possibilities from win32 to UNIX in small and middle-sized workplaces and in 3rd party software vendor's market.
- For easy interoperability of new Kexi applications with software that is locked-in win32 platform. Many businesses are in fact locked-in win32 platform because they rely on given amount of NOT PORTABLE, specialized software.
Development Hints
Let's look at exisitng software that integrates with ODBC layer. Especially, there is valuable option to see into QSQL QODBC3 driver/plugin's source code, even if QSQL API is just a subset of what KexiDB try to offer.
ODBC <-> KexiDB: Redundant & common terms
All things described below need to be integrated and hidden in Kexi API / infrastructure:
- ODBC itself has its own Driver Manager.
- ODBC has its own drivers, administered via config files or GUI.
- User DSN - personal Data Sources. System DSN - admin's Data Sources. These need to be integrated with (more generic) KexiDB Connection Data Sources and its GUIs.
ODBC Integration with Kexi / KexiDB / KDE
There are few GUIs for administering on ODBC layer. We'll need to think how to integrate these elements with Kexi configuration framework, especially when in the future Kexi would export own configuration GUI as the KDE Control Center Module.
Existing ODBC configuration GUIs are a bit obsolete, not well integrated into KDE framework.
It shouldn't be to hard to introduce generalized config GUI that also covers ODBC configuration. Naming convention can be a bit different (more generic). Existing configuration framework is pretty similar to one what we may need for Kexi.
See also: Dublin/aKademy2006 Discussions about ODBC Support in Kexi and KDE.