Database library

I’ve been looking for a database library for Ada.
My “requirements” are: Connects to various database servers, but Oracle is most important, and runs on Linux. Freeware or similar (I’m a retired developer, coding just for pleasure)
What I have found that is available is adaoci, but this is only Oracle. Still this is what I will use unless I find better.

  • QtAda seems to be tied in with a costly (for me) Qt platform. I could be wrong about that, but it still seems very overkill, since the Qt platform is huge and complicated (could be wrong about that, too). Also, download links seems to end up on porn sites.
  • Matreshka seems promising, but I cannot figure out where to download it from. The links I find to Matreshka seem to be either outdated or closed/block (due to the war perhaps).
  • SOCI-Ada requires C++ (not a great fan), but I will look further into this.

So, are there anything better available? Does anyone know where I can download Matreshka?

Matreshka has been moved to github, see GitHub - godunko/matreshka: Matreshka Project

3 Likes

Excellent. Thank you very much.
I suspected as much, but the old location kept popping up in “all” my google hits.

You might be interested by this: KonAd - Software für Kontrolle und Administration .

2 Likes

I stumbled across KonAd and KonAda by watching the presentation “Database Programming with Ada” - Piron, 2010. It looks very interesting. A different approach to database API.
My main “objection” is that it seems that KonAda needs to be rebuilt for each specific ORACLE_HOME setting. Of course, this could be a misunderstanding from my part. So, I will be looking into changing the build method so that ORACLE_HOME can be provided in as a run-time parameter. Alternatively - or rather - more likely, I will consider using KonAda source in my project(s). As long as I’m only toying around and have no intention on distribution, I guess that shouldn’t be a problem.

My conclusion for now is to focus on Oracle connection only. Building and configuring Matreshka seems to be above my head at this point in time (since the whole Ada environment is new to me). So, I will probably be looking further into KonAda or AdaOCI. Perhaps SQL*Module for Ada.

For those interested, the video and slides of this presentation are available on the following web-page of the Ada-Europe 2010 conference in Valencia, Spain (together with many more):
http://www.ada-europe.org/conference2010/outcome.html

1 Like

If your database supports the open database connectivity standard there is also Simple Components which has ODBC thick Bindings (and thin if you need something special)

I’m using Linux, so ODBC is not a good option. There is, of course, unixODBC, but that is not very good. I was hoping for something similar to JDBC, but it seems that I will “settle” for KonAda. The loss is interdatabase operability, but that is not a big deal.

Is there anywhere to ask questions about the use of konAda?
I’m stuck.

I’d try an e-mail (see contact page: KonAd - Software für Kontrolle und Administration)…
Perhaps there is a copy of the software on some open-source portal.

Actually it is.
We use ODBC for MS-sql-server and Oracle. from Linux and Windows.
I find it much easier than OCI for Oracle.
Homebrew binding on top of GNADE. (Needs update for 64-bit)
But Kazakov’s version is likely very good.
The only reason we are not using it is that we hade an API to maintain - designed long time ago.
And that we did not know of it at the time.
Otherwise we would have used it.

/Björn

I’ll admit it’s been some years (at least 18) since I looked into unixODBC. Thanks for the tip. I look into it

I’ve got konAda downloaded and installed. However, I am having problems linking my test program (it is throwing a segmentation error) through GNATStudio. The konAda included examples (with a gnatmake makefile) works as it should.

I’ll look into other forum threads and such. This is definitely something related to gprbuild