From: "James Britt (rubydev)" Date: 2001-12-08T12:11:42+09:00 Subject: [ruby-talk:27889] Re: DBI and large result sets > You may want to consider the BerkeleyDB (ruby/bdb ?), which gives a high > performance Hash (among other things). Just a bunch of name/value pairs, > where the name and/or the value can each be up to 4Gb long. > > Good disk management, fast, and uses shared memory by default, so works well > as a persistent intercommunications scheme between programs. > > And even better: no database server (unless you want one, like if you have a > remote database)! > > Locking, secondary keys, etc. if you need them. > > Unless you need SQL (it doesn't sound like you do), that is. Thank you for the information. I've only briefly used BerkeleyDB with perl I'm looking to design this so that it doesn't require any particular database. I want a general-purpose "treat any db as an XML stream" tool. Changing databases shouldn't break it. I have it working, though I don't think it avoids the potential memory hit. If that's unavoidable as a consequence of using the DBI abstraction layer, then perhaps that's just something I have to live with. It's still quite handy. The main goal was to explore Neat Fun Things (NTF) you can do with Ruby & XML, and it does actually solve a practical problem for me. One other option may be to change the constructor to accept a greater variety of DB-specific objects, and provide specific wrappers that allow them to plug in to the DbSource. Sort of like putting DBI-ish qualities into the DbSource class itself. James > > (note: MySQL is built on top of BerkeleyDB). > > -- > Ned Konz > currently: Stanwood, WA > email: ned@bike-nomad.com > homepage: http://bike-nomad.com > >