I am creating a game and need to save some data from my database locally on the device. This data will update often and all of it will update at once and never needs to be searched. The data from the database is in JSON format. I am debating whether or not to store this data as a JSON file in the documents directory or as a text or blob field in a sqlite database. If I go with the JSON file is there any protection when using the i/o library to prevent an error and only half the new data being written? If not I was thinking of just storing the entire JSON object as a blob in sqlite which makes sure the entire save is completed before deleting the old data. Any thought on this issue would be very helpful.
Thanks.