Importing database: newbie issue
wes weston
wweston at att.net
Thu Jan 22 10:39:01 EST 2004
Angelo,
If doing this on an ongoing basis, you might
look at using shelve.
from "Python Essential Reference", pg 81
import shelve
object = someObject()
dbase = shelve.open(filename) #open a database
dbase['key'] = object #save object to db
...
object = dbase['key'] #retrieve object
dbase.close()
Angelo Secchi wrote:
> Hi,
> I have a database with a fixed format structure (i.e. i know the
> starting point and the length of each of the field composing the
> database) and I would like to extract from it only few fields (ex the
> one starting from the 32nd position with length 12...).
> What is the best way to do that?
>
> Thanks
> a
>
More information about the Python-list
mailing list