Storing video files in database
I have an application containing database with pictures. I also wanted the database to contain some videos. Is it possible to store videos in databas开发者_运维知识库e by converting them to byte array or other format?
You could store a binary object within a database, but why bother? Simply store the path/file name to the pictures/videos.
The mediastore content provider has a standard way of doing this. On this page look for MediaStore
Documentation
The example is for images, but if you get the mime type right and write the data to the stream correctly it should work.
精彩评论