Re: Flattening attributes
Re: Flattening attributes
- Subject: Re: Flattening attributes
- From: Rico Landefeld <email@hidden>
- Date: Thu, 16 Feb 2006 10:24:04 +0100
--- Begin Message ---
- Subject: Re: Flattening attributes
- From: Rico Landefeld <email@hidden>
- Date: Thu, 16 Feb 2006 10:20:43 +0100
Ian Joyner schrieb:
The problem I have found with flattened attributes is that they seem
to work fine for one thing but not for another. You have to test them
out on all four CRED operators (create, read, edit, delete). Often I
find that EO generates strange errors about inv paths not being found
when deleting, etc. I have tried them out in order to perform joins
to make access more efficient, but usually some other problem turns
up. Perhaps I'm just not proficient at them yet.
Your design also seems a little restrictive, large companies can have
multiple addresses, so shouldn't you make this a to-many relationship
– in that case flattened attributes will not be possible and will
just make your design less flexible for future 'feature requests'.
hi ian, there is not need for to many relationships at this point. my
dbcontext delegate seems to work. but its really hacking. i think the
flattening feature is meaningful for my use case. but it doesn't work
correctly. for more details look at my email to ken.
regards,
rico
On 15/02/2006, at 10:11 PM, Rico Landefeld wrote:
hi all,
i have the following problem with flattening. i have an address
entity in
my eomodel wich is used by many other entities like company. company
has a
to-one relationship to address. i like to flatten some of the address
attributes into company (address is a weak entitytype). if i insert an
company without filling the address fields there is no insert into the
address table. when some address fields are filled, eof generates an
insert for address but without an primary key and the address
relationship
of the company object is empty! i have written an big
EODatabaseContext.Delegate to handle this. is there a better solution?
Whoa, that definitely seems like a bad idea, but maybe those who are
further down the track than I could advise (who said "if you are
writing code in EO, you are doing it wrong"). Have you tried 'Owns
destination' and 'Propagate primary key' in the advanced relationship
pane in EOModeler. But be careful, you have to understand the
semantics of these exactly.
Ian
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
--
__________________________________
Rico Landefeld
Takwa GmbH
Softwareentwickler
Bodelschwinghstr. 25
99096 Erfurt
Tel.: +49 361 6534096
Fax.: +49 361 6534097
eMail: email@hidden
WWW: http://www.takwa.de
__________________________________
--- End Message ---
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden