Anonymous Asked in Cars &Transportation · 2 weeks ago

Can you save files in SQLite?

SQLite is a liteweight component. Instead of storing files like . pdf and . doc in SQLite,store them in internal storage and get the path in internal storage and now store that in SQLite as a string. 12 мар. 2015 г.


Can SQLite store pdfs?

You can simply read all the bytes of the pdf file and store them in the blob field of sqlite DB, but a better solution which is highly recommended is to store the files on the Internal Storage and in your DB just store the file's path. You have also to check if there is enough memory storage for you.

Can I store image in SQLite?

Inorder to store images to android SQLite database, you need to convert the image uri to bitmap then to binary characters that is, bytes[] sequence. Then set the table column data type as BLOB data type. After retrieving the images from DB, convert the byte[] data type to bitmap in order to set it to imageview.

Related Questions

Relevance
Write us your question, the answer will be received in 24 hours