del table[id] is more picky. Raises an exception if id is not int and if the record does not exist.
On Friday, 14 February 2014 16:23:04 UTC-6, Horst Horst wrote: > > I have a controller function for record deletion which worked reliably for > quite some time. > > Today I've added > > added auth.enable_record_versioning(db) > > to my model file for the first time (my tables had auth.signature fields > already). > > Since then, I get > > <type 'exceptions.SyntaxError'> No such record: 230 > > tickets whenever I call > > del db.piece[id] > > However, > > db(db.piece.id == id).delete() > > works fine. > > (And yes, the records *do* exist.) > > I've found this thread here > https://groups.google.com/forum/#!topic/web2py/rNv8oARIttI where someone > appears to have a similar problem. (There's no conclusion though.) > > -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.