Algorithm to Convert 15-Digit ID to 18-Digit ID
Salesforce.com Record ID's exist in 2 forms
- The 15-Digit case-sensitive form
- The 18-Digit case-insensitive form
How to get Record ID's?
- URL (after logging in Salesforce and clicking a particular record)
- Salesforce Reports
- API
- SOQL (Salesforce.com Object Query Language)
Reports and Object ID's
- Salesforce Report returns 15-Digit ID's
- The Report framework does not expose ID's for all objects
API and Object ID's
- The API always returns 18-Digit ID's
- For updates, the API will accept either the 15-Digit or 18-Digit format
Algorithm to Convert 15-Digit ID to 18-Digit ID
Step 1
Step 2
Step 3
Step 4
Step 5
Step 6