How can I keep my data from saving if pcall fails?

Use UpdateAsync and place all the code that can error in it. It’s more reliable than SetAsync and will only update the data once you return a value that isn’t nil.

As an added bonus, it parses the previously saved value. This way you can modify that value and even compare it to the currently present data to check if you want to keep it or not.

If the save actually fails, then the data won’t be updated. If you aren’t doing some random error like game.Worrrsspace = 1, then you will know by if the pcall is successful or not if it saved or not.
You will know if it saved by if the pcall is successful or not, as long as you don’t do a weird error inside the pcall.
Here’s an example of having a backup save:

local function saveData(key, val)
  local success, em = pcall(function()
    dataStore:SetAsync(key.."1", val)
  end)
  if not success then print(em); return end
  success, em = pcall(function()
    dataStore:SetAsync(key.."2", val)
  end)
  if not success then print(em); return end
  return true
end

He’s purposefully erroring the function wrapped inside the pcall() call after :UpdateAsync() has been called.

I’m not sure why though, :UpdateAsync() won’t update any data if it errors itself.

If your pcall failed and it wasn’t due to SetAsync, then what the hell would be failing?

If your intention is to call a function that returns whatever it needs to as the second parameter for SetAsync, just… pcall that function before the SetAsync… And then check if that pcall failed separately before doing SetAsync().

Otherwise, what your trying to do isn’t possible and your explanation is nonsensical.