Reputation: 2206
I'm currently working on a client-side project with Html5 and javascript. I need create a large database (almost 2GB), and also I need to make this database portable. In other words, I actually need to store the database into a binary file, migrate it, and retrieve its information.
As the result of my recent research I found two good solutions (especially for Android and IOS)
But none of them really helped me. I should mention that my application is going to work on Desktop, Android, IOS, and any other platform that is going to support most of HTML5 features.
I should also mention that my DB is preloaded.
Upvotes: 2
Views: 2496
Reputation: 3794
I would highly recommend JSON, This article will explain some more: Databases using JSON as storage/transport format
I have personally used this one before which works well and loads its DB from a JSON: http://www.persvr.org/
JSON can be index if you create them corerctly, there basicly fully flexible and good for stroing, as far as i know they dont have any limitations as there just big strings when stringify and objects when parsed, Is there a limit on how much JSON can hold?
Also something similar has been asked before: Using JSon like a Relational SQL Database (Javascript)
Upvotes: 3
Reputation: 10260
I have personally found that it is better to write my database tables to json format, and then store the json into local storage as a string. This means your javascript will be able to easily access and modify the data client side, and what ever your using on the backend should be pretty happy working with it to put it back into what ever database your using if needed.
Upvotes: 0