2

Hi

I need to insert thousands of records into Android - SQL LITE database, on first time of app installation. what is the optimize way to handle this situation. should i Hard code those records in LIST (code) or fetch from File System i.e, CSV or txt or its any other way?

nalaiqChughtai
  • 1,179
  • 2
  • 9
  • 15

1 Answers1

1

I would suggest you to keep your database file in the assets folder and the copy it into databases folder for the first time your application starts. Inserting thousands of record won't be a good idea if you are having static data in your tables.

Lalit Poptani
  • 67,150
  • 23
  • 161
  • 242