> mapper(Document, documents, properties={
>     'document_id': documents.c.id,   # document_id ORM property

> In the past, I have successfully mapped these properties using
> synonym, but this time I'm confused because I'm not sure how to
> define the synonym to a different column name. How do I change my
> 'document_id': declaration in the mapper call to set up the above
> descriptor when accessing the id column on the table?

if u use '_document_id' in above mapper(..) would that be enough? no 
synonim, just diff.property-name


--~--~---------~--~----~------------~-------~--~----~
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 
sqlalchemy+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to