Questions tagged [childrelationship]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2 votes
1 answer
2k views

Didn't Understand Relationship - How To Find Child Relationship Name?

I have a many-to many relationship between three objects. LGFProducts, PartsinProducts, and Parts. PartsinProducts is the junction object. I want to be able to get data like the names of the parts ...
user1470901's user avatar
0 votes
1 answer
4k views

Multiple Sub Query using child parent relationship

Consider in my basket, I have a package (Main Product-just a holder) which will have 2 standalone products (child) and again the standalone products will have child products (Grand Parent). All these ...
user47200's user avatar
8 votes
2 answers
17k views

Didn't understand relationship in FROM part of query call [duplicate]

I am trying to query the child record using the parent record id. I understand that we have to use the child relation name in the inner query to get the child records. select id, (select id from ...
SfdcBat's user avatar
  • 4,751
7 votes
1 answer
164 views

Programmatically Determine Which Objects Allow Lookup References to Them?

I'm wondering if there is a way, via apex, to retrieve all objects that would allow a lookup field on another object to reference them. For example, for a custom object obj1__c, I can create a lookup ...
Gary Hammell's user avatar
3 votes
4 answers
2k views

Sub-Querying Objects, Plural Relationship Name?

This may be pretty basic I've come across something in SOQL I'm not sure I totally understand. List<Contact> con = [SELECT Id, (SELECT Id, Name, CreatedDate, ContentType FROM Attachments WHERE ...
Dan Jones's user avatar
  • 7,147
0 votes
1 answer
372 views

assign lookup of accountId contact value on case field (Compile Error: Invalid foreign key relationship: Contact.cases )

i'm fetching data from soql need to insert account lookup value(accountId) and contact lookup value (ContactID) in case create from email services here is my code: String con_Email = envelope....
cloudZigZag's user avatar
  • 1,366