Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android SQLite alternatives [closed]

I'm building a simple android RPG. Each player has access to a maximum of about 50 soldiers. Each soldier has some stats (class, hp, attack, etc), and three inventory slots. There will be only about 100 items in the game to fill these inventory slots. I was hoping to set up a relational database that would have a table for soldiers, a table for items owned, and a few other various tables.

Speed is my main concern. SQLite is the obvious first choice. However, it seems to be very bulky and geared towards databases with 1000's of rows. Is there a better option for small databases? I don't need complex queries or anything, just a way to store data and back it up to a server.

like image 585
Jake Marzen Avatar asked Feb 03 '15 14:02

Jake Marzen


People also ask

What is the alternative for SQLite in Android?

But if you want to replace SQLite completely, there are also quite a few alternative databases: Couchbase Lite, Interbase, LevelDB, Oracle Berkeley DB (formerly Oracle's mobile database was "Oracle Database Lite"), Realm, SnappyDB, Sparksee Mobile (graph database, brand-new at the time of this article), SQL Anywhere, ...

Is there any other database than SQLite that you can implement in Android?

Yes. The Android library provides native support to only SQLite. Of course, this doesn't mean you absolutely can't use other databases on Android; if you need to use other databases, you'll have to either look for already-existing third-party libraries(1), or roll out your own API.

Is SQLite obsolete?

Save this answer. Show activity on this post. In which case, does that mean that SQLLite is deprecated in Android? No.


1 Answers

There are two nice libs that make data persistance in Android much quicker and simpler to implement as follows;

Cupboard > https://bitbucket.org/littlerobots/cupboard (backed by sqlite)

Realm > http://realm.io/news/realm-for-android/

Realm is the newer one and seems slightly better but both seem to have similar implementations.

Hope this helps.

like image 50
Andy B Avatar answered Sep 30 '22 11:09

Andy B