A lightweight wrapper around SQLiteOpenHelper which introduces reactive stream semantics to SQL operations
Questions tagged [sqlbrite]
46 questions
0
votes
1 answer
Sqlbrite run insert and query operations simultaneously, the query will get a null result
The app has two fragments in the same activity. Fragment A have a button then press the button will start a parallel task, that will insert or update a lot of records in the database. Fragment B included a ViewPager, the ViewPager is using…

KpSt
- 43
- 8
0
votes
1 answer
Errors when testing database repository - SQLBrite, SQLDelight
When testing my DB I get the following errors:
SQLiteDiskIOException: disk I/O error (HTC Desire 620)
SQLiteReadOnlyDatabaseException: attempt to write a read-only database (Moto g2)
Depending apparently on the device I test it on.
The error…

Lukasz
- 2,257
- 3
- 26
- 44
0
votes
1 answer
SQLBrite how to pass parameter to createQuery
I am using sqlbrite for my chatting app. I need to observe a database, but the range is not fixed.
Observable messages = db.createQuery("messages", "SELECT * FROM users WHERE timestamp > ? ");
I need to pass in an argument…

OMGPOP
- 1,995
- 8
- 52
- 95
0
votes
1 answer
Android app install with Failure [INSTALL_FAILED_DEXOPT] Android 2.3.x devices
I have an app composed of multiple modules which I have just updated from rxjava1 to rxjava2. Now there is no way to install it on android 10 devices or emulators. On compile time, no errors but installs fails either from android studio or command…

vallllll
- 2,731
- 6
- 43
- 77
0
votes
1 answer
How to concat data from two observables
I have two observables:
Observable profileObservable = briteDatabase.createQuery(UserMapper.Table.NAME, sql, String.valueOf(userId)).mapToOneOrDefault(UserMapper.MAPPER, null);
Observable
- > carObservable =…

Tom Wally
- 542
- 3
- 8
- 20
0
votes
1 answer
How to convert a Android SqlBrite model class to implement Parcelable
I am building an app where I am using SQLBrite sql wrapper for all my database operations. Also, I am using Auto Value to handle all my getters and setters automatically using Google AutoValue library.
Now, my issue is to handle the device rotation…

Nithin Prasad
- 554
- 1
- 9
- 22
0
votes
1 answer
Rxjava2 approach similar to backpressure for BiFunction
I used sqlbrite to listen the changes of table a and b. And use combineLatest operator to combine observables produced by sqlbrite. In the BiFunction process the emitted items of observableA and observableB.
private CompositeDisposable…

KpSt
- 43
- 8
0
votes
1 answer
Cursor in observable not closed on orientation change
While running on strict mode, when the orientation of the phone change, my app will crash with the error
A resource was acquired at attached stack trace but never released.
See java.io.Closeable for information on avoiding resource leaks.
…

imin
- 4,504
- 13
- 56
- 103
0
votes
1 answer
Use PreparedStatement with Sqlbrite
I'm migrating all my sql related codes to use Sqlbrite. Currently I have code that look something like this:
Cursor cursor;
String name;
String[] selectionArgs = { name };
cursor = database.query(MySQLiteHelper.TABLE_USER, new String[] {"id"}, "name…

imin
- 4,504
- 13
- 56
- 103
0
votes
2 answers
SqlBrite cannot use AndroidSchedulers.mainThread()
I'm beginner in using sqlbrite, rxjava. So, I must run some code on a UI thread(to be specific add some markers on the map from a coursor that I have from updated db SELECT query).
Here is my starting setup:
sqlBrite = new…

K.Os
- 5,123
- 8
- 40
- 95
0
votes
1 answer
createQuery useage trouble about SQLBrite and SQLdelight
I use SQLdelight to create sql code,Like
SELECT * FROM CoachService WHERE shop_id in (?) and brand_id = ?
and I query Like:
briteDatabase.createQuery(CoachService.TABLE_NAME, CoachService.GETBYBRANDIDANDSHOPS, "'1','5','11'","2");
but result is…

paperhs
- 194
- 2
- 6
0
votes
1 answer
Why is onNext not getting called when using toList?
I'm having an issue with onNext not getting called when using the RxJava toList operator. Everything works exactly as I expect up until the toList gets called. Things I've read here, here and here seem to indicate the issue with onCompleted not…

apicellaj
- 233
- 1
- 3
- 16
0
votes
2 answers
RxJava data flow with SqlBrite and Retrofit
In my Android app I am using domain level Repository interface, which is backed with local DB implemented using SqlBrite and network api with Retrofit observables. So I have method getDomains(): Observable
- > in Repository and two…

Oleg Osipenko
- 2,409
- 1
- 20
- 28
0
votes
1 answer
Trigger SqlBrite to update from Stetho debug bridge
I'm using SqlBrite for reactive database updates, and Stetho for debugging. From stetho, I can insert a new row into the database from the SQL console. Is there any way I can get this row I've manually inserted to trigger SqlBrite to update my UI?

eliasbagley
- 1,237
- 9
- 17
-1
votes
2 answers
Why isn't my sql query in sqlite/sqlbrite not working with a second condition/multiple WHERE clauses?
I have a query for my Sqlite/Brite databse that takes two conditions. One to check for a selected quarter, and another to make sure an action attribute isn't "delete". When I only have the WHERE clause to check for the selected quarter, I get all…

Carter
- 179
- 11