KDb/About KDb: Difference between revisions

From KDE Community Wiki
< KDb
No edit summary
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
'''KDb is a database connectivity and creation framework for various database vendors.'''  
'''KDb is a database connectivity and creation framework for various database vendors.'''  


'''KDb is consisted of a general-purpose C++/Qt-only library and a set of plugins.''' Because there is no dependency on [[Kexi]], [[Calligra]] or even on KDE libraries, KDb is developed for a wider audience. Kexi since the version 3 uses it too, thus deprecating [[Kexi/KexiDB|KexiDB]].
'''KDb is consisted of a general-purpose C++/Qt-only library and a set of plugins.''' Because there is no dependency on [[Kexi]], [[Calligra]] or even on KDE libraries, KDb is developed for a wider audience. Kexi since the version 3 uses it too, thus deprecating KexiDB.
 
'''Unlike QtSQL, KDb 'knows' how to create database and new tables.''' It has a Qt/C++ API for that. There is no need to pass SQL at all but you can pass if you wish (it will silently parse your statements before contacting the database). KDb is developed as a next generation database handling layer for Kexi and similar complex apps.
 
The main downside at the moment: it's not yet released and its API isn't frozen, so early adopters need to install a copy of it. Once released source and binary compatibility will be maintained.


'''KDb is widely free/libre software available under the [http://en.wikipedia.org/wiki/LGPL GNU Lesser General Public License (LGPL)].''' Thus, developers are free to:
'''KDb is widely free/libre software available under the [http://en.wikipedia.org/wiki/LGPL GNU Lesser General Public License (LGPL)].''' Thus, developers are free to:
Line 11: Line 7:
*extend it for specialized use cases
*extend it for specialized use cases
*contribute directly to KDb
*contribute directly to KDb
== KDb and Qt SQL ==
KDb has a slightly different architecture and requirements than Qt SQL.
Unlike QtSQL, KDb 'knows' how to create database and new tables and it has a public C++ API for that. You do not need to pass raw SQL statements to KDb at all in order to use this feature. But passing the SQL statepents is possible if this is what you wish. KDb is event able to parse the  statements before contacting the database.
KDb is developed as a a data/database handling layer for KEXI and similarly complex apps.
In turn, Qt SQL has poorer error handling. For example, it is often problematic with Qt SQL to recognize whether the connection failed because the database does not exist or because the password was wrong. Qt SQL error values aren't sufficiently rich to provide such  information. Developer sometimes try to parse the error messages, what makes the application code complex and hard to maintain.


==History==
==History==
*KDb is a new iteration of KexiDB library developed within [[Kexi]], part of the [[Calligra|Calligra Suite]] (formerly KOffice). Its codename was recently known as Predicate.
KDb is a new iteration of a connectivity library developed since 2003. It was previously known as KexiDB. The development happens within the [[Kexi]] application project. Even if KDb's release schedule is synchronized with KEXI's schedule at the moment, there is no technical dependency on KEXI.  
 
*Read about history of the project in the [http://commit-digest.org/issues/2010-12-12/ KDE Commit-Digest].
*Read about history of the project in the [http://commit-digest.org/issues/2010-12-12/ KDE Commit-Digest].

Latest revision as of 00:01, 27 August 2023

KDb is a database connectivity and creation framework for various database vendors.

KDb is consisted of a general-purpose C++/Qt-only library and a set of plugins. Because there is no dependency on Kexi, Calligra or even on KDE libraries, KDb is developed for a wider audience. Kexi since the version 3 uses it too, thus deprecating KexiDB.

KDb is widely free/libre software available under the GNU Lesser General Public License (LGPL). Thus, developers are free to:

  • use KDb in applications, also commercial
  • extend it for specialized use cases
  • contribute directly to KDb

KDb and Qt SQL

KDb has a slightly different architecture and requirements than Qt SQL.

Unlike QtSQL, KDb 'knows' how to create database and new tables and it has a public C++ API for that. You do not need to pass raw SQL statements to KDb at all in order to use this feature. But passing the SQL statepents is possible if this is what you wish. KDb is event able to parse the statements before contacting the database.

KDb is developed as a a data/database handling layer for KEXI and similarly complex apps.

In turn, Qt SQL has poorer error handling. For example, it is often problematic with Qt SQL to recognize whether the connection failed because the database does not exist or because the password was wrong. Qt SQL error values aren't sufficiently rich to provide such information. Developer sometimes try to parse the error messages, what makes the application code complex and hard to maintain.

History

KDb is a new iteration of a connectivity library developed since 2003. It was previously known as KexiDB. The development happens within the Kexi application project. Even if KDb's release schedule is synchronized with KEXI's schedule at the moment, there is no technical dependency on KEXI.