On 08/01/2009, at 4:22 AM, Piotr Kęplicz wrote:
> > Joe Riopel, środa 07 stycznia 2009 17:45: >>> Session.query(Person).filter_by(...).delete() >> >> Isn't that code still doing the select first, to get the object, and >> then deleting it? > > No. It's a Query object turned into a DELETE statement, just like > first(), > all() or one() would turn it into a SELECT statement. In your Pylons config (development.ini) you can enable "sqlalchemy.echo = true" to see all the SQL statements in the logfile. That helps to get a good understanding of what SA is actually doing. Cheers, Chris Miles --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pylons-discuss" group. To post to this group, send email to pylons-discuss@googlegroups.com To unsubscribe from this group, send email to pylons-discuss+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/pylons-discuss?hl=en -~----------~----~----~----~------~----~------~--~---