home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!spool.mu.edu!agate!apple!apple!cambridge.apple.com!bill@cambridge.apple.com
- From: bill@cambridge.apple.com (Bill St. Clair)
- Newsgroups: comp.lang.lisp.mcl
- Subject: Re: Database Implementation Naivete
- Message-ID: <9211091648.AA21770@cambridge.apple.com>
- Date: 9 Nov 92 17:52:33 GMT
- Sender: info-mcl-request@cambridge.apple.com
- Lines: 36
- Approved: comp.lang.lisp.mcl@Cambridge.Apple.C0M
- Full-Name: Bill St. Clair
- Original-To: Kevin G. Joback <Kevin@SCANDIUM.mks.dialnet.symbolics.com>
- Original-Cc: info-mcl
-
- >I am considering implementing a database in lisp for managing
- >information on chemicals. Till now I have been saving objects to files
- >and then reloading them. With the number of chemicals now approaching
- >2000 this process takes too much time. Additionally I never take
- >advantage of having all the information loaded.
- >
- >My needs are quite minimal. No transaction restarts or SQL (yet).
- >
- >I thought a file in a specified, fixed format could be used to store the
- >information. The FILE-POSITION function would be used to move around the
- >file. READ-CHAR, WRITE-CHAR, READ, WRITE, etc. used to retrieve and store
- >information.
- >
- >Being inexperienced in this area I have several questions:
- >
- >1) Is this approach likely to work? I know commercial databases offer
- >numerous capabilities which probably make them very complex to implement
- >but can one start small?
-
- You can certainly do it with that approach, but READ-CHAR & WRITE-CHAR
- will likely be quite slow. You'll end up spending a lot of time
- managing the memory in the file and indexing your information so that
- you can find it. I've written a simple object oriented database that
- may fit the bill. It's called "Wood" and is available for anonymous
- FTP from cambridge.apple.com in the file "/pub/mcl2/contrib/wood-0.5.sea.hqx".
- If you don't want to download the whole thing, the documentation is
- in the file "/pub/mcl2/contrib/wood.doc".
-
- >
- >2) Are there any references which discuss the implementation of simple
- >databases? I have found countless books on database architecture and
- >implementation issues but none on how to sit down and start coding.
-
- I don't know of anything. For Wood, I read a little bit about B-trees and
- transactions & recovery (which is not yet part of Wood, but will be
- eventually if I get the time to work on it), then started coding.
-