Which is the best way to implement –
- Fetch the first 25 records and display when user click on more then again fetch from the server.
- Fetch all the records from the server and store in DB and fetch 25 records from DB and display in table and repeat.
- Or any other suggestions.
Fetching all records at the same time and then displaying in fractions is an approach but NOT a good one as loading for the first time will take a lot of time while fetching them from the web server.
You simply cannot ask user to wait for too long when it comes to making apps for iOS or any other mobile platform.
Also fetching 100000 items does not make sense because no one will want to go through all of them.
If the records are static, then you should consider adding them in DB and pre-loading with the app.
If the records are not static, for example, if its a website and more records are updated in it, then fetching and loading in small fractions is the right choice and when user demands more, you fetch and load more.