[DB-SIG] dbm to gdbm conversion

M.-A. Lemburg mal@lemburg.com
Thu, 23 Nov 2000 18:10:06 +0100


Patrick Ladam wrote:
> 
> Hi all,
> I am a real newbie in python (and db too...) and so will ask what you
> will probably consider a dumb newbie question...
> Here is the situation: I use a scientific soft that works both on
> a unix and a linux platform. This soft uses dbm on unix and gdbm on
> linux as you guessed.
> thus I'd like to convert the dbm databases into gdbm databases (and
> vice-versa) for exchangin data.
> I could not find any converting function in any module (dbm, anydbm, gdbm...)
> and would like to know if that is doable and ...how to do it.

Wouldn't it be possible to read in the database in Python,
store it in a dictionary, write it as pickle to a file
and then do the exact reverse on the target machine ?

I've never used dbm, but the Python interface looks like it
uses a simple mapping interface.

-- 
Marc-Andre Lemburg
______________________________________________________________________
Company:                                        http://www.egenix.com/
Consulting:                                    http://www.lemburg.com/
Python Pages:                           http://www.lemburg.com/python/