Re: [Modeling-users] toOne relationship returns base class instead of subcl
Status: Abandoned
Brought to you by:
sbigaret
|
From: Sebastien B. <sbi...@us...> - 2004-07-23 19:01:24
|
John Lenton <jl...@gm...> wrote:
[...]
> actually, what's biting me is this (I'm translating from a different
> model into this one that is similar to the example, for clarity and
> brevity; I hope I don't muss ep):
>=20
> >>> [i.getPerson().getId() for i in ec.fetch('Address')]
> [4, 5]
> >>> ec.fetch('Address', 'person.id =3D=3D 4')
> []
>=20
> in trying to simplify this last time I got the behaviour above, which
> I misinterpreted as the same thing.
Quickly replying here: this is absolutely not normal, and it would help
a lot if you could provide a sample model, code and data (sal dump is
ok).
Or maybe you were trying something like this? ->
>>> [i.getPerson().getId() for i in ec.fetch('Address')]
[4, 5]
>>> ec.fetch('Person', id =3D=3D 4')
[]
instead of:
>>> ec.fetch('Person', id =3D=3D 4', isDeep=3D1) # fetch the whole inheritc=
e tree
[<PhysicalPerson instance at 0x...>]
-- S=E9bastien.
|