function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
chris_centrachris_centra 

Odd Child Relationship label - R00*

Hello.  I'm building some Apex code - writing a query where I grab a parent and certain child records.  The Parent is Conference and the child is Attendee.  So I would expect the inner query to be SELECT Id FROM Attendees__r...  This wasn't working so i checked it in the schema browser and I see the following:

 

Select c.Name, c.Id, (Select Id From Sessions__r), (Select Id, Name From R00N50000001QtE7EAK) From Conference__c c

 

I checked the schema browser and the relationship name is indeed R00N50000001QtE7EAK.  How/Why is this happening?  Is there a way to change it?

 

Thanks

Chris

 

 

 

Best Answer chosen by Admin (Salesforce Developers) 
Rajesh ShahRajesh Shah

You can change the relationship name.

Go to the field which defines the relationship between the two. There you will see the Child Relationship Name. Edit, provide your name and save.