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
David KaszyckiDavid Kaszycki 

API Help Needed - can't determine API name for fields with data type 'lookup(user)' and 'hierarchy'

I am using APIs to populate an iPad app and have had no issues pulling most fields, but I am stuck on how to pull the data from 2 different fields: 
  1. Account Owner - data type is Lookup(User). This is supposed to pull the Salesforce user who is listed as the account owner. (Field name is "Owner")
  2. Parent Account - data type is Hierarchy. This is supposed to pull the Parent Account of the Account show - i.e. J&J is the parent account of Band-Aid. (Field Name is "Parent", Child Relationship Name is "ChildAccounts)
Naren9Naren9
Hi David,
Are you looking for SOQL to get the above fields Data from Salesforce by using REST API?

Thanks,
Naren
David KaszyckiDavid Kaszycki
We are using the REST API. 
Naren9Naren9
you can use the SoQL as   SELECT Id, Name,owner.Name,Parent.Name from Account  to fetch the data from Salesforce to iPad app.