The problem is LOAD RECORD. My LOAD RECORD calls the 4D plugin API
version of LOAD RECORD, which mistakenly deletes the copy in the cache
before loading. If the record is newly created in the cache and the
cache has not been flushed, the data file will be corrupted.
I will work around this in v2.1. Until that comes out, you have two
ways to avoid this problem:
1. Call FLUSH BUFFERS after SAVE RECORD
2. Make a 4D method wrapper for LOAD RECORD and call that.