RE: [sqlalchemy] update existing row

2011-08-01 Thread King Simon-NFHD78
vitsin wrote: > hi, > can't figure out why raw SQL works fine, but update() is not working: > 1.working raw SQL: > self.session.execute("update public.my_table set > status='L',updated_at=now() where my_name='%s'" % (self.my_name)) > > 2.non working update() from Alchemy: > s = aliased(MyTable) >

[sqlalchemy] update existing row

2011-07-30 Thread vitsin
hi, can't figure out why raw SQL works fine, but update() is not working: 1.working raw SQL: self.session.execute("update public.my_table set status='L',updated_at=now() where my_name='%s'" % (self.my_name)) 2.non working update() from Alchemy: s = aliased(MyTable) query = self.session.query(s).fi