Hello all,
I'm a newcomer to SA, using it as the ORM for TurboGears at the
moment.

Is there documentation/tutorials/recipes somewhere about how to
properly use SA from TurboGears?

The problem I'm hitting at the moment is how to properly select simple
objects... There seems to be two main approaches, for example:
session.query(Ownership).select() or
ownership_table.select().execute()

With the first approach, I get
InvalidRequestError: Parent instance <class 'tnf.model.Ownership'> is
not bound to a Session, and no contextual session is established; ...
which I'm not sure how tackle - there's no mention I can find of when
and where create_session should be called...

The the second approach, the SELECTs work fine, but then I'm working
with RoxProxy objects, rather than my models, which don't have the
relations and back-references I've set up and that I obviously need.

Can anyone answer these specific questions or point me in the
direction of some further documentation?

Thanks,
James


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to