Re: accessing the primarykey???
Re: accessing the primarykey???
- Subject: Re: accessing the primarykey???
- From: Hugi Thordarson <email@hidden>
- Date: Tue, 13 Jul 2010 10:49:21 +0000
Good morning Ted.
You can use EOUtilities.objectWithPrimaryKeyValue or EOUtilities.objectWithPrimaryKey to accomplish this.
You *can* also expose the PK in your EOModel and ERXKeys will be generated for it in your EO templates (you expose an attribute with the diamond-looking-thingy-button when editing an attribute). However, exposing the PK is (generally considered) bad practice, so don't do that unless you must. I just like giving out bad advice every now and then.
Cheers,
- hugi
On 13.7.2010, at 10:41, Theodore Petrosky wrote:
> I need a qualifier that gets a primary key...
>
> is the primary key accessible in a qualifier like this?
>
> versionQual = Version.JOB.dot(Job.<primaryKey()>).eq(something);
>
> My primary key is the Job Number....
>
> Ted
>
>
>
> _______________________________________________
> 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
_______________________________________________
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