So I have an iphone app that downloads data from a shared database. It switches between views and when it returns to the "data" view I'd like to download only the new data in the database. What is the best way to achieve this?
views:
91answers:
1
+1
A:
Are the rows in the tables of the database unique? Off the top of my head, you could store the list of table row ids that you already know of then compare against that when reading the "new" rows (unless the existing rows will change their data).
Nick Bedford
2009-09-27 22:27:20
The existing rows can change. They are timestamped though. i guess I can use that but I was worried about this not scaling well.
ennuikiller
2009-09-27 22:32:19
As far as implementation goes (not performance), the two things I would do is store timestamp against row id and use those to compare against incoming changes. That's as minimal as could I think of approaching it, really.
Nick Bedford
2009-09-27 23:13:30