Compound Fields in Salesforce

Compound fields in Salesforce group together multiple elements of primitive data types, such as numbers or strings, to represent complex data types, such as a location or an address. Compound fields are an abstraction that can simplify application code that handles the values, leading to more concise, understandable code.

Address compound fields are available in the SOAP and REST APIs in API version 30.0 and later. Geolocation fields are available in the SOAP and REST APIs in API version 26.0 and later, with some limitations on SOAP for API versions below 30.0.

Example:

BillingAddress, MailingAddress.

Salesforce Lead Compound Field:

Salesforce Account Compound Field:

Salesforce Contact Compound Field:

Compound Field SOQL:

SELECT Id, Name, BillingStreet, BillingState, BillingCountry, BillingPostalCode
FROM Account
WHERE Name = 'InfallibleTechie'

Leave a Reply