You need to sign in to do that
Don't have an account?
Lacevedo
How to join to TAbles with Sforce API
I want to join two relational tables with its respective relation ids.
for example, I want to join Account and Contact table with
with Account.Id = Contact.AccountId.
Hi Lacevedo,
Create a dataset. Add 2 datatables and make sure that the id of the master is in the master and in the child. Set the primary key on the master to be the id of the master. Create a Relationship object using the primary key of the master and the foriegn key of the child. Voila, you have joined the 2 tables in the dataset.
My question is similar to this. What I need to do is to download some contacts using some query like:
select firstname, lastname from contact c
inner join account a on a.accountId = c.accountId
where a.AccountTerritory = 'United States'
Can I do this with SOQL? Or there are other ways I can retrieve contacts by criteria in related tables?
Thanks.