Date: prev next · Thread: first prev next last
2017 Archives by date, by thread · List index


On Fri, Jan 13, 2017 at 01:44:42PM +0100, Bunth Tamás wrote:

I'd like to have a better understanding of how the hsqldb and jdbc
drivers work.

Is there any wiki page for them like "FirebirdSQL" for firebird that
I couldn't find?

Nah, I don't think so, not on the TDF/LibreOffice wiki. There are some
on the OpenOffice wiki, but not what (I think) you are looking for:

https://wiki.openoffice.org/wiki/Base/connectivity/HSQLdb#HSQLDB
https://wiki.openoffice.org/wiki/HSQLDB_Integration
https://wiki.openoffice.org/wiki/HSQLDB:Tips_and_Tricks
https://wiki.openoffice.org/wiki/HSQLDB_Localization

The code in connectivity/source/drivers/jdbc contains a bunch of java
function calls afais. So where are the java codes, and how does the
driver call them?

The Java code is in the JDBC driver, that is loaded from the
system. In the case of embedded HSQLDB, the JDBC driver is bundled
with LibreOffice and is handled in the build system by
external/hsqldb. It is installed as instdir/program/classes/hsqldb.jar
You'll find the source in workdir/UnpackedTarball/hsqldb/

There is also instdir/program/classes/sdbc_hsqldb.jar; I think this
contains the hack to redirect HSQLDB writes directly into the
in-memory ZIP structure of the ODB instead of to a file. The actual
source code to that is in connectivity/source/drivers/hsqldb/Storage*
and connectivity/com/sun/star/sdbcx/comp/hsqldb

The embedded HSQLDB is mostly just the JDBC driver, with some extras
specific to HSQLDB in connectivity/source/drivers/hsqldb

(In the case of HSQLDB, "JDBC driver" is a bit of a misnomer, since
JDBC is the native API of HSQLDB.)

-- 
Lionel

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.