Mike Bernson пишет:
> use the lockmode='update' on a query object.
>
> row_obj = query_obj.select(where, lockmode='update').execute()
>
self.localTowns = Table('local_towns', self.metadata,
Column('id', Integer, primary_key=True),
Column('title', Unicode(50)),
mysql_engine='InnoDB')
self.localTowns.create(checkfirst=True)
item = self.localTowns.select(self.localTowns.c.id==itemId,
lockmode='update').execute()
and I got this error :-(
File "/usr/lib/python2.4/site-packages/sqlalchemy/sql.py", line 1332,
in select
return select([self], whereclause, **params)
File "/usr/lib/python2.4/site-packages/sqlalchemy/sql.py", line 65,
in select
return Select(columns, whereclause = whereclause, from_obj =
from_obj, **kwargs)
TypeError: __init__() got an unexpected keyword argument 'lockmode'
--
Basil Shubin
Freelance Software Developer
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---