Solution 1 :
You should go for Room Database
As per android developer docs:
The Room persistence library provides an abstraction layer over SQLite to allow fluent database access while harnessing the full power of SQLite.
Room Database is the best.
Also, has support for RxJava as well as LiveData and Flows.
I recommend using Flows.
Problem :
I’m trying to program a simple android app with database connection, however I’ve only recently started with Kotlin and so far, even after several hours of searching, I haven’t found an understandable tutorial that shows how to enter/read something into a database via Kotlin…. Can anyone help here or has a good tutorial?
I’ve tried SQLiteOpenHelper so far, since I haven’t found an alternative for MySQL (both MySQL and SQLite are installed and set up on my server). However, with SQLiteOpenHelper, I can’t seem to specify a password to authenticate with the database….
Comments
Comment posted by mrvinrsk
First of all, thanks for taking the time to answer, but I think my question was a bit misleading; from what I’ve read Room Database is a local database on the respective Android device, but I need access to an external database as the data should be retrievable across devices, do you have a tutorial or similar on this as well, if possible using MySQL or SQLite in conjunction with a password for authentication? As I said, so far I have only found the SQLiteOpenHelper, which apparently can not pass a password and which apparently also only uses a local database…