You need to sign in to do that
Don't have an account?
Losintikfos
SOQL
Hi Guys,
Do anyone know why this statement is not working?
SELECT Id, Name FROM Account WHERE Id IN (SELECT FirstName, LastName FROM Contact where AccountId ='00120000008rnQJAAY')
Cheers.
I think i found the answer here: relationship query
All Answers
The obvious reason is that you're trying to compare ID's from Account to a query returning FirstName and LastName from contact.
The not-so-obvious reason is that when I try to use an IN clause with another query inside, I get a message telling me that semi-joins are not supported with this version of the API (tested using the Apex Explorer v8.0).
Oh see!
So do anyone knows how to make join SOQL statement?
I think i found the answer here: relationship query