There are no concurrent operations on the table, and it seems like some objects in the table occasionally lock up. When they locked up all repeated attempts to save will fail. Creating a new table everything will work again until objects starts locking up again.
The game is under development, so I'm the only user, and this is the code I'm using:
- Code: Select all
_client.bigDB.loadOrCreate("scores", team.code, function (o:DatabaseObject):void
{
if (o.points != null)
{
o.points += team.points;
} else
{
o.points = team.points;
}
if (o.games != null)
{
o.games += 1;
} else
{
o.games = 1;
}
o.save(false, false, onSaveTeamScoreComplete);
},
onSaveScoresError);
Any ideas what I might be doing wrong would be greatly appreciated.