What better ways are there to storing user data in a DataStore?

Yes, why do you care about the old data? That’s what I have been asking the entire time.

We care about old data because if the SetAsync() errors then all the data is lost, but if it errors with UpdateAsync() the old data was not erased so it has something to fallback on.

Where does it say that on the wiki? None of the error handling pages on datastores say this.

That is completely irrelevant. If the SetAsync errors, it makes no sense for it to delete the data. If it can’t access Roblox servers, how would it delete the data?

I don’t know what to tell you at this point. All I can tell you that my game experienced a lot of data loss issues with SetAsync() and I switched to UpdateAsync() and I havn’t had the same data loss issues.

Other people are also saying exactly what I’m saying:

1 Like

(Taking the post that is saying to use UpdateAsync, rather than the few that aren’t.)

It looks like they’re talking about when you’re using multiple scripts to access to same datastore, which makes sense. I agree with using UpdateAsync in that case, thanks for linking these threads.

Np sorry for the bad discussion I’m really bad at explaining things

1 Like