On Sun, Dec 6, 2009 at 8:07 PM, Jean-Christophe Deschamps <j...@q-e-d.org> wrote: > >> > From what I read, it is necessary to have a programmatic interface to >> > put images into a database. True? >> >>yes, but I am not sure what other kind of interface there could be? >>You can't imagine putting an image into a sqlite db through the >>command line shell application. Of course, you can build your own >>application that allows the user to select, view and upload an image >>that then gets inserted into the db. > > Certainly not the right answer! > > On the contrary SQLite will happily insert blobs like this one: > > x'424D3E0000000000000036000000280000000200000001000000010018000000000008000000C40E0000C40E00000000000000000001FFFFFFFFFFFF0000' > > It is a 2x1 pixel in .BMP format I just made for showing it's fairly > easy to do. > > Whatever the OS you use, I believe there are myriad of command-line > tools able to output a byte after byte hex dump of any kind of binary > data. Enclose that with X'' put this inside your SQL command file and > you're done. > > It may not be the prefered way in most application, but it's > nonetheless possible. >
You are correct. You proved that it is possible. part 2: What are the usual and convenient ways of inserting images into a sqlite db? answer: Programmatically. -- Puneet Kishor _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users