Data base and searching bar using tinyDB

We are trying to make a data base for our app, and we found that tinydB can be use to make it. But our data include photos (a lottt) and also text because it is traffic sign so it includes the picture of that sign, its name and also its meaning. So we got stuck in coding. And now we are really need some tutorial.

  1. Can the database and all the image storage exist locally on the device?
  2. If so, store the images to a location of your choice and store the links to those images in your tinyDB.
  3. If not, then you will need an online database and image store to do the same thing.

This topic is vast.....

Well, another approach would be an SQL database stored on the phone - it very much depends on image size and quantity. If the images are relatively small (and optimized for Android) then they can be saved as "blobs" in a database or, maybe worth a try, stored as "text" in Base64 format. You can save Base64 format to TinyDb, but you need to test performance.

There are extensions available for converting to and from Base64. Just build a simple test App and experiment :grin:

Hi Jane.

This seems to be a discussion about what to do about the information collected in the discussion Local image searching bar (Classify or read the contents of road signs). Is it? It might be helpful to the community to know why you are attempting this. :slight_smile:

I would tackle this as a 6 column CSV table in the Media folder, with columns:

  • short traffic sign name ("Yield to chickens crossing the road")
  • text color of sign ("black")
  • background color of sign ("yellow")
  • sign shape ("triangular")
  • short file name of picture (make the files small as possible)
  • paragraph of text explaining the sign more

This allows filtering by various attributes (color, shape, keywords in name (yield, etc.)

Yes, it is . We 've made the image searching bar. And now stuck with data base ;.;

@Jane_Lily this example save an image in TinyDB

Here is a sample database search app for small in-memory tables like your traffic sign collection.

1 Like