[Zope3-Users] Re: crud/read example?

Philipp von Weitershausen philipp at weitershausen.de
Sat Sep 2 11:51:47 EDT 2006


Robert Hicks wrote:
> I was just wondering...

Create:

   >>> from worldcookery.recipe import Recipe
   >>> recipe = Recipe()
   >>> folder['dead_chicken'] = recipe

Read:

   >>> folder['dead_chicken']
   <worldcookery.recipe.Recipe object at XXX>

Update:

   >>> recipe = folder['dead_chicken']
   >>> recipe.title = u'Dead chicken'
   >>> recipe.description = u'Beat it to death'

Delete:

   >>> del recipe['dead_chicken']


Welcome to the wonderful world of Zope's object database (ZODB).

Philipp



More information about the Zope3-users mailing list