[Zope-DB] updating fields in a zsql method programmatically

Maciej Wisniowski maciej.wisniowski at coig.katowice.pl
Mon Aug 27 12:27:07 EDT 2007

> changed_field1 = "a new computed value"
> field1 = changed_field1
> #create a new record with form field results for field2 & field3, and a
> computed value for field1
> context.insertNew()
Obvious things are sometimes hardest to find ;)


field1 = changed_field1

or even:

context.insertNew(field1='something', field2=other_variable)

It is more clear than getting values from context I think.

Maciej Wisniowski

More information about the Zope-DB mailing list