From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,2675917c17c43125 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!t-online.de!news-lei1.dfn.de!news1.uni-leipzig.de!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: "Alex R. Mosteo" Newsgroups: comp.lang.ada Subject: Re: Ada and PostgreSQL Date: Tue, 23 Jan 2007 16:42:39 +0100 Message-ID: <51mom4F1l5v9lU1@mid.individual.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Trace: individual.net KGHmhxY3jVjlMMpZthWxPAPhyNw+s5sIJO9hJOtDI3s2cyi7w= User-Agent: KNode/0.10.4 Xref: g2news2.google.com comp.lang.ada:8427 Date: 2007-01-23T16:42:39+01:00 List-Id: Maciej Sobczak wrote: > Hi, > > I must have been quite a pain for you recently with my questions and > nit-picking ;-), but at the end I have finished my exercise and built a > *very* simple Ada client library for PostgreSQL. > You can find it here: > > http://msobczak.com/prog/bin/pgAda.tar.gz > > Please consider it as a starting point for what should be a *true* > database library, but there are also chances that in simpler projects it > might be exactly what is needed. > > Your comments are of course welcome. Have you taken a look at GNADE postgresql binding? It has some points in common to yours; it is more limited in some aspects (transactions and query parameters). I'd look into making transactions in such a way that declaring it in some scope provides automatic operation, e.g.: declare T : Transaction (Db'Access); -- Automatic start of transaction -- via Initialize begin Query (.... T); -- Automatic rollback on failure here end; -- Automatic commit on Finalize I'm doing it with a wrapper over Gnu.Db.Postgresql and it is quite handy. In any case is nice to see more support for this database.