operation in python once we've installed compatible zodbwe begin by first creating database\pp \dbase\zodb- xpython from zodb import filestoragedb storage filestorage filestorage( ' :\temp\mydb fs'db db(storageconnection db open(root connection root(this is mostly standard "boilerplatecode for connecting to zodb databasewe import its toolscreate filestorage and db from itand then open the database and create the root object the root object is the persistent dictionary in which objects are stored filestorage is an object that maps the database to flat file other storage interface optionssuch as relational database-based storageare also possible adding objects to zodb database is as simple as in shelves almost any python object will doincluding tupleslistsdictionariesclass instancesand nested combinations thereof as for shelvesimply assign your objects to key in the database root object to make them persistentobject ( 'spam' 'you'object [[ ][ ][ ]object {'name'['bob''doe']'age' 'job'('dev''mgr')root['mystr''spam root['mytuple'object root['mylist'object root['mydict'object root['mylist'[[ ][ ][ ]because zodb supports transaction rollbacksyou must commit your changes to the database to make them permanent ultimatelythis transfers the pickled representation of your objects to the underlying file storage medium--herethree files that include the name of the file we gave when openingimport transaction transaction commit(storage close(\pp \dbase\zodb- xdir / :\temp\mydbmydb fs mydb fs index mydb fs tmp without the final commit in this sessionnone of the changes we made would be saved this is what we want in general--if program aborts in the middle of an update taskthe zodb object-oriented database