Bugs item #1885802, was opened at 2008-02-03 18:59
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=540672&aid=1885802&group_id=74338
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: General
Group: SQLObject release (specify)
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Till Maas (tmaas)
Assigned to: Nobody/Anonymous (nobody)
Summary: SQLObject should determine joinColumn from Class Name
Initial Comment:
Currently SQLObject determines the joinColumn for MultipleJoin from the name of the table.
In the documentation it is recommended to use "user_table" as a table for an class called User. When one now creates another class, e.g. Address that has a ForeignKey from User in a column called "user", one needs to add joinColumn='user_id' to the MultipleJoin definition within the User class, otherwise one only gets a totally strange python traceback, when one tries to access u.addresses.
I attached a simple example, that makes it more clear, where the problem here is.
I use python-sqlobject-0.9.2-1.fc7 from Fedora.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=540672&aid=1885802&group_id=74338
|