So, cherrypy.request.sa_transaction.connection should work.
I had tries that. But it says Exceptions :'function' object has no
attribute 'execute' Don't know why.
Sanjay
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
conn = session.context.get_current().connection(SomeMappedClass)
conn.execute(...)
Thanks! It is exactly what I needed.
BTW, the session transaction is stored in
cherrypy.request.sa_transaction. Does this help simplify the
statements?
thanks again,
Sanjay
Sanjay ha scritto:
BTW, the session transaction is stored in
cherrypy.request.sa_transaction.
Yes, but it's been added recently.
Does this help simplify the statements?
Transaction instances have a connection() property.
So, cherrypy.request.sa_transaction.connection should work.
Sanjay ha scritto:
Need help on how to do it. Being a turbogears application where db
entities like metadata and session are imported rather than created by
me, I am confused and could not successfully implement the pattern
provided in the docs.
I'm sure there are cleaner ways, but this
Marco Mariani wrote:
Sanjay ha scritto:
Need help on how to do it. Being a turbogears application where db
entities like metadata and session are imported rather than created by
me, I am confused and could not successfully implement the pattern
provided in the docs.
I'm sure