Datastore Inquiry

My game has used the same datastore since 2015, and as of now, it only contains each player’s respective points. As of recent, however, I’m looking to implement a level system so people can start spending their points without losing their progress since 2015, so my solution to that is integrating levels to show a player’s experience rather than their points.

Is there a way to edit the datastore and say:

“Hey, for every 10 points this person has, let’s increase their level”

Question: Am I able to do this by having a script go through the whole datastore or do I have to have a script calculate this when a player joins the game.

I’m just asking for what I can use to accomplish this, I know it’s basic, and I know in a game it wouldn’t be wise to increase a level every 10 points, rather gradually increase that interval, but I’m just using that for basic purposes right now.

As far as I know, the only way you could go through all the current values of a data store is if you stored all data in a single array value, or you had a separate list of all the players in it.
However, you can put a script in the game that checks their XP, and if it is nil, then it converts any previous points they had into XP.

Except instead of 0, check if it’s nil. If they have points but their experience is nil, assume they’re a player with old data and give them the experience they would have based on their points.

Using experience is better especially in the testing phase as it allows you to modify the level-up logic later. Their level should only be a number that gets displayed to them based on their experience.