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
tjeppesetjeppese 

Do Salesforce ID's ever get reused.

Salesforce IDs are of course unique, and they remain stable for a given object during that object's lifecycle.

We intend to use the ID to keep an external database synchronizd with data from Salesforce.

 

If an object is deleted in Salesforce (and also deleted from the recycle), that object will no longer be synchronized but it will be kept in our external database for historical reasons.

 

Is there any possibility that the Salesforce ID at some time will be recycled and suddenly represent a totally different object?

werewolfwerewolf
No, as far as I know Salesforce.com IDs are globally unique and intend to stay that way.  By my estimation, even for the most heavily used objects, Salesforce.com can handle at least 75 billion more rows per object before it has to start doing something about the IDs (and even if they do have to add more at some point they'll probably just make the IDs longer).
SuperfellSuperfell
Well, they're only unique for a given orgId, not globally unique (e.g. Ids in sandbox can be the same as the Id from the source org the sandbox was created from, and other sandboxes created from that org.)