Dont know how to use TinyDB with more then one app

I have read a lot of posts (but not all) about sharing a tinydb component between 2 or more but it look like I dont quite get the thing.
I want to have the same DB between 2 apps
Both are called DB1 and both are in the same NameSpace (TinyDB1)
But a query from my second app returns no result (other than the specified on in such cases).
My firs app looks first in DB1 before starting and works well.
Any ideas?

You must have a database that can be shared. A TinyDB is not a shared database. It is unique to the device.

Consider using a CloudDB or FirebaseDB or TInyWebDB or using a Google Spreadsheet as a database.

Use one of those databases to update a TinyDB on each device.


You cannot use the TinyDB to pass data between two different apps on the phone or between devices, although you can use the TinyDB to share data between the different screens of a multi-screen app.

The ActivityStarter shows one way you might be able to share TinyDB info with a second app on your device (but not the TinyDB). Using the Activity Starter

Thanks for your reply.
I forgot to say that I need it on the SAME device

You could use sqlite, as long as your database file is available in a shared location (this possibly becomes more difficult in Android > 10 or API > 29).

See Taifun's extensions page which will offer you some options

Very clear!
I see I should had read tinyDB documentation better where it is clearly stated!
Thank you to all for your help.

I'll try with a file like /myfile.txt