These are chat archives for gdg-hudson-valley/android-guide

Mar 2015
Ivan Fernandes
Mar 25 2015 03:38
Hi @nitya, as promised I have a question:
The app up until lesson 5, fetch weather data from the server whenever the refresh button is pressed. It fetches the data and stores it. I don't see anywhere in the code they deleting this data, just storing. If I press the refresh button more than once in an interval small enough that the data from the server is the same in all those refreshes, the database will get some "duplicate" rows. On the Loader query we set the sortOrder to sort the data by the date, so in my view it should show some duplicate data as response right? for example if I have 3 identical forecasts for tomorrow among the data in the database, when I query sorting by date I should get all this data together. But that does not happen. So my question is why i'm not getting duplicate data on the forecast list?