A string containing the server change token for the record.
- iOS 8.0+
- macOS 10.10+
- Mac Catalyst 13.0+
- tvOS 9.0+
- watchOS 3.0+
When you fetch a record from the server, you get the current version of that record as it exists on the server. However, at any time after you fetch a record, other users might save a newer version of the record to the server. Every time a record is saved, the server updates the record’s change token to a new value. When you save your instance of the record to the server, the server compares the token in your record with the token on the server. If the two tokens match, the server knows that you modified the latest version of the record and that your changes can be applied right away. If the two tokens do not match, the server applies the save policy your app specified to determine how to proceed.
In your own code, you can use change tokens to distinguish between two different versions of the same record.