[plt-scheme] PLT and Database access

From: Matt Jadud (mcj4 at kent.ac.uk)
Date: Fri May 27 03:55:52 EDT 2005

For my dissertation work, I've done the unthinkable, and hacked 
libraries. Therefore, my scripts are (currently) stuck with SchemeQL, 
spgsql, and v209. That said, it works great, everywhere.

Some time ago, I ripped the SrPersist backend out of SchemeQL, and 
plugged in spgsql. I did this for portability---at the time, I saw no 
way to reasonably get my code running under Linux, FreeBSD, Solaris, and 
MacOSX without spending entirely too much time dealing with binary 
compatibility issues at the ODBC layer (yes, I may have made the wrong 
choice). The result, however, is that I have a macro system at the front 
end for specifying queries, and a pure-Scheme Postgres driver at the 
back. This means I can have one Subversion repository for my code from 
which I can check it out and run it, anywhere, on a locally replicated 
database. (Assuming, of course, PLT v209.)

I have no idea what kind of performance penalties I may or may not pay, 
but I do not care. However, I'm now faced with the fact that I cannot 
move this (casually) to v300 without porting both SchemeQL and spgsql 
myself---a situation I knew I'd get into. So, I have frozen the scripts 
for analyzing my data at v209. Kids, this is what happens when you edit 
the library; never edit the library.

I'm making a list of projects to poke at after I finish writing up; 
perhaps giving SchemeQL an API at the backend would be a useful thing, 
so the various DB implementations can all use it as a front-end. I won't 
even think of touching that until October, however.


nishad at ptolemy.tlg.uci.edu wrote:
> What are people in the PLT world using to talk to databases like MySQL
> and Postgres?  
> I'd love to hear of something that simply *works*; failing that, I'd
> like to know of any real experiences with any other packages.  There
> must be *some* success stories out there...?

Posted on the users mailing list.