foo = MultipleJoin('bar') does not create attribute foo
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
foo = MultipleJoin('bar') does not create attribute foo.
Instead it creates 'bars' whatever the left hand side of =.
Though I know joinMethodName='foo' does what I want
but it still needs = and the left hand side.
Here's a snipet from joins.py line 115
if name.endswith('s'):
name = name + "es"
else:
name = name + "s"
self.joinMethodName = name
This is quite a magic, and not documented. Actually
what the documentation says is """
It can also be created automatically, and is normally
implied (i.e., addresses = MultipleJoin(...) implies
joinMethodName="addresses").
"""
By the way if I simply call MultipleJoin('bar') it doesn't
set attribute at all.
Logged In: YES
user_id=4799
This is a duplicate of the bug 1175278.