Re: Letting the user enter the compound primary key in D2W
Re: Letting the user enter the compound primary key in D2W
- Subject: Re: Letting the user enter the compound primary key in D2W
- From: "Jerry W. Walker" <email@hidden>
- Date: Thu, 6 Apr 2006 09:20:54 -0400
Hi, John,
On Apr 6, 2006, at 3:36 AM, John Gilmore-Baldwin wrote:
Alas. Sounds like I can't get out of this jam by just going to a
regular old
WO app. I'd resort to perl if the platform had a driver I could use.
I may actually have to go with a pure java GUI solution. Just like
the old
days. At least with Foam I don't have to write GridBagLayout code
anymore.
Thanks, Chuck. To the extent one thanks another for spoiling their
dreams of
solving a problem easily :)
Alternatively, you might try talking the user out of using editable
primary keys for all the obvious architectural reasons, and then do
the right app in WO.
Regards,
Jerry
John
P.S. Just for the record, I agree about editable primary keys.
On 4/5/06 3:31 PM, "Chuck Hill" <email@hidden> wrote:
On Apr 5, 2006, at 1:00 AM, John Gilmore-Baldwin wrote:
I’m trying to use Direct To Web on a legacy database system. I’m
not too familiar with D2W.
In this legacy database, there is a compound primary key, but the
user needs to be able to edit it.
That is pretty much flat out not possible. EOF won't save changes to
a primary key. You will get an exception when you call save
changes. Even if you could save the changes, it would mess up EOF's
object store as it does not expect the PK to change and bases the
EOGlobalID on it. Editable primary keys and EOF are mortal enemies.
I feel that way about editable primary keys myself. :-)
The only remotely possible way that I can see of to do this is to not
bind the UI to he EO values, use raw rows or raw SQL to update the
key values directly, and then calling invalidateAllObjects on the
root object store. Shudder.
Is there an easy way to get D2W to show the key? I made the key
fields class properties in EOModeler, but the fields still didn’t
show up.
That I don't know.
Chuck
--
John Gilmore-Baldwin
Information Systems Director
111 Bethel Street N.E.
Olympia, WA 98506
Tel (360) 754-5497
Fax (360) 754-4221
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40gmail.com
This email sent to email@hidden
--
__ Jerry W. Walker,
WebObjects Developer/Instructor for High Performance Industrial
Strength Internet Enabled Systems
email@hidden
203 278-4085 office
_______________________________________________
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