[Chicago] SQLAlchemy presentation

Massimo Di Pierro mdipierro at cs.depaul.edu
Fri Sep 11 07:32:04 CEST 2009

Hi Daniel,

thank you for your SQLAlchemy presentation. It was inspiring. In fact,  
I did not know SQLAlchemy could handle "on delete cascade" with sqlite.
This is an important feature that web2py (currently) does not have. So  
I have now implemented this feature in web2py and it is in trunk.
Here is an example:

python web2py.py -S welcome -M
 >>> db.define_table('a', Field('name'))
 >>> db.define_table('b', Field('name'),  
 >>> ida = db.a.insert(name='xxx')
 >>> db.b.insert(name='yyy', a=ida)
 >>> db(db.a.id == ida).delete()

More information about the Chicago mailing list