From: Slobodan Blazeski
Subject: announcement monetdb-mapi
Date: 
Message-ID: <1187773246.360446.250690@r23g2000prd.googlegroups.com>
I want to announce the monetdb-api project, starting with set of cffi
bindings for monetdb mapi library. This lower layer is still
incomplete but you could connect and interact with the database, in a
c/c++ style,i know it sucks but will improve that later,  for the
example of the interaction with mapi see intro.lisp file that roughly
resembles http://monetdb.cwi.nl/projects/monetdb/SQL/Documentation/An-Example.html#An-Example
c/c++ example. Later  I will complete the bindings, I need to find
some time to read cffi docs more thoroughly about handling pointers,
files & streams, and add some automatic testing than I'll proceed with
implementing the upper layer and/or maybe integrating it as backend
for clsql or elephant, but I still didn't decided about that.
I opened a project at common-lisp.net but untill I understand how to
commit files with cvs or any other way  I'll host monetdb-api at
googlepages  http://slobodan.blazeski.googlepages.com/monetdb-mapi.html
as  prolonged exposure to windows definately crippled me, as I can't
do anything without GUI .
If anybody is interested in monetdb from the *nices I would be happy
if suggests what library to load at
(define-foreign-library libmapi
    (:windows "libMapi.dll"))
That's only windows specific thing I use, i tested with lw and allegro
and later depending of my free time i'll try to install and test with
sbcl.

Thanks to Luis Oliveira for CFFI  http://common-lisp.net/project/cffi/
and Daniel Albuschat  http://code.google.com/p/fbsql/  for
inspiration.

cheers
Bobi

From: Zach Beane
Subject: Re: announcement monetdb-mapi
Date: 
Message-ID: <m34pird9of.fsf@unnamed.xach.com>
Slobodan Blazeski <·················@gmail.com> writes:

> I opened a project at common-lisp.net but untill I understand how to
> commit files with cvs or any other way  I'll host monetdb-api at
> googlepages  http://slobodan.blazeski.googlepages.com/monetdb-mapi.html

I downloaded the source and took a look at it.

It's customary to have zip files and tar.gz files unpack into a new
directory, rather than into the current directory.

It's a little odd that you have two separate (and very different)
defpackage forms for the MONETDB-MAPI package. You should just stick
with just one.

The asdf defsystem doesn't specify any dependencies among
components. Normally, you'd indicate that, for example, mapi.lisp
depends on packages.lisp with a :depends-on clause, or by using
:serial t and putting the file compnents in a particular order.

There are plenty of editors that have integrated CVS support. Emacs is
the one I use. It's easy.

Zach
From: Slobodan Blazeski
Subject: Re: announcement monetdb-mapi
Date: 
Message-ID: <1187853676.661109.294020@i38g2000prf.googlegroups.com>
On Aug 22, 2:40 pm, Zach Beane <····@xach.com> wrote:
> Slobodan Blazeski <·················@gmail.com> writes:
> > I opened a project at common-lisp.net but untill I understand how to
> > commit files with cvs or any other way  I'll host monetdb-api at
> > googlepages  http://slobodan.blazeski.googlepages.com/monetdb-mapi.html
>
> I downloaded the source and took a look at it.
>
> It's customary to have zip files and tar.gz files unpack into a new
> directory, rather than into the current directory.

Yes, fixed that.
>
> It's a little odd that you have two separate (and very different)
> defpackage forms for the MONETDB-MAPI package. You should just stick
> with just one.

It was mistake , fixed.
>
> The asdf defsystem doesn't specify any dependencies among
> components. Normally, you'd indicate that, for example, mapi.lisp
> depends on packages.lisp with a :depends-on clause, or by using
> :serial t and putting the file compnents in a particular order.
Serial t is fine in my case , added.
>
> There are plenty of editors that have integrated CVS support. Emacs is
> the one I use. It's easy.
Maybe easy for you, I don't use nor like Emacs,so I need to figure out
how to do it with TortoiseSVN .
>
> Zach
Thanks for your comments .

Bobi
From: Slobodan Blazeski
Subject: Re: announcement monetdb-mapi
Date: 
Message-ID: <1188807778.214291.231720@19g2000hsx.googlegroups.com>
New version with some high level code is uploaded at
http://slobodan.blazeski.googlepages.com/monetdb-mapi.html
Most improtant things are probably execute and query :

Execute should be used for non queries, returns no of rows affected
(execute "create table my (name varchar(30), age int);")
=>0
(execute "insert into mytab (name, age)  values('Tom', 29);
=>1
(execute "insert into mytab (name, age)  values('Sarah', 19);
=> 1
Query , should be use for selects, returns list of all rows and
columns
(query " select * from mytab;")
=> (("Sarah" 19) ("Tom" 29))
    ("name" "age")


cheers
bobi


Cheers

bobi
From: Slobodan Blazeski
Subject: Re: announcement monetdb-mapi
Date: 
Message-ID: <1190188078.590944.291700@19g2000hsx.googlegroups.com>
Monetdb-mapi passed the experimental phase and now is in early alpha:
1.Added documentation in pdf, txt, html & doc format.
2.Improved upper layer  with
- multiple running of prepared queries
- manually iterating over rows
- resetting the cash of the query
3. Partially covered with test via Lisp-unit
http://www.cs.northwestern.edu/academics/courses/325/readings/lisp-unit.html

It's still parked at googlepages, http://slobodan.blazeski.googlepages.com/Monetdb-mapi.html
because author refuses to learn Emacs,  probably his suffering from
prolonged exposure to *modern* ides, so his unable to unable find out
how to upload it to common-lisp.net  .
Actually he's not trying to learn that, except in mondays, reminded by
friendly autonags.


cheers
Slobodan Blazeski