I am currently trying to make a database system where an officer can input a player name, and it will return that player’s criminal record. I was tinkering around with the code from my previous question and I found out that it does get more than 8 values, but the way I was saving the values was not working properly (if that makes sense).
This is a pretty straight-forward and general question but how do I get the amount of values in an ordered datastore in order to properly save a value?
I’ve tried
for name, value in pairs(dataPages) do
print("a value")
end
and
for i = #dataPages,1,-1 do
print(i)
end
and originally
local dataAsync = recordDataStore:GetSortedAsync(true,100)
local dataPages = dataAsync:GetCurrentPage()
recordDataStore:SetAsync("Value",#dataPages+1)
but all of these don’t seem to work properly. I’ve tried searching everywhere and even asked other websites with no help.