0

I am using sqlite DB in my android application.(created the db in sdcard)

is this possible to insert single large file into db.(say around 20-30mb)

if not what is the alternative solution.and what is the size limitation to insert

surya
  • 477
  • 1
  • 7
  • 19
  • 20 / 30 MB is a lot of data... anyway, I think it's possible but you're preformance will be a lot slower I predict. –  Nov 03 '11 at 10:12
  • What sort of file? Do you want to populate the DB from a CSV file? – Andrei Nov 03 '11 at 10:13
  • actually i want to insert video files, to stop user from stealing the videos. – surya Nov 03 '11 at 10:21

2 Answers2

0

For size limitations, see this post.

An alternative is to place whatever this "large file" is in the assets folder.

What exactly is the scenario?

Community
  • 1
  • 1
Ricky
  • 7,785
  • 2
  • 34
  • 46
0

SQLite can handle large amount of data, the problem here is the device's limits. If you are going to store more than 10MB , you should consider saving that data in an external server and access it via the Internet. If you are building an application that use large amount of data, usually the application don't use all data all the time, so you can save in cache (in a local database) . if your db file is limited in size less than 10 MB you can encrypt them and put it in the sdcard

jennifer
  • 8,133
  • 22
  • 69
  • 96