Simon Fell > Its just code > Apex and FKs

Monday, September 08, 2008

Apex and FKs

Just like i described yesterday for the API, you can do exactly the same foreign key resolution using external Ids in Apex code, e.g.

Case c = new Case(subject='Apex FKs');
Account a = new Account(extId__c='00001');
c.account = a;
insert c;
< 8:41 PM PDT # > tags : Salesforce.com Web Services [playing "Delerium" by Euphoria (from Brazilification Disc 1)]

You can't post a Comment

Sorry i got sick of comment spam, have something to say about one of my posts, post it to your own weblog.