> the model here doesn’t illustrate how this would be a many-to-many. 
A User can have any number of other Users as a favorite. That looks quite 
many-to-many to me....
This is a simplified version of my structure:

User:
- serial id (pk)
- bool is_deleted

FavoriteUser
- user_id (pk, fk to User.id)
- target_id (pk, fk to User.id)

> yeah that’s the lambda + string together which is not the correct use.
If i put just a string I get the same:
sqlalchemy.exc.ArgumentError: Column-based expression object expected for 
argument 'primaryjoin'; got: '(User.id == user_id) & ~target.is_deleted', 
type <type 'unicode'>
With a lamda there error is gone though. That's one step closer :)

I guess with the way I have my relationships setup at the moment, I'd need 
to access the join from the `target` relationship from the backref of the 
`user` relationship?

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sqlalchemy+unsubscr...@googlegroups.com.
To post to this group, send email to sqlalchemy@googlegroups.com.
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/d/optout.

Reply via email to