the question about refresh is that the select for lock at least on mysql will read the record and use the copy stored in the database even if not the same as the one in transaction. Since I have set the refresh always to true this does not matter to me for now.
I will be willing to get the query object to handle the lockmode for parameter. I can at least get the lockmodes for mysql working. After the query object handles the lockmode I can look at getting the patch for the session object as well. Does select off the table handle nowait ? I will look at how the select off the table handle for_update and use that as a template for dealing with query select/load/get stuff. Please let me known you want me to handle it or Andrija ? Michael Bayer wrote: > anyway, would either of you care to try creating patches for some of > this ? if you can get the basic idea going I can clean up as > necessary before committing. > > Id say its somewhat straightforward to get the "lockmode" argument > into query.get/select, as well as getting Oracle to look for > "for_update='nowait'". > > with regards to the lock() method, someone said that it should > "refresh the object". i think Hibernate's policy is that it loads > the object only if it has not been loaded already. if we refresh an > already-loaded object, what happens to changes that have already been > made on the instance ? > > to do session.lock, its essentially a call to query's _get with the > proper arguments. id not worry about cascading to start with ( i can > get cascading in later on). if we really want it to refresh (which > im not so sure about), it involves sending the "refresh=True" flag to > _get(). > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > Sqlalchemy-users mailing list > Sqlalchemy-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/sqlalchemy-users ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Sqlalchemy-users mailing list Sqlalchemy-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sqlalchemy-users