Click to See Complete Forum and Search --> : database sQl server ?


pareshgh
December 16th, 2002, 07:12 PM
Hi,

I am dealing with several image files. I have a SQL-Server as a database server. how do I save these images in a table (as jpeg/bmp/gif) formats and later retrieve in the same format. ?

I need to store video also in database (NOT ON HARDDISK FILE).

any hints on this topic would be appreciated ...
Thanks,
Paresh

Arild Fines
December 17th, 2002, 11:28 AM
SQL server has an 'image' field type. Using this, you merely convert the image into an array of bytes(try saving it to a MemoryStream) and insert it the usual way.
The same goes for video(image can be used for any kind of binary data).

pareshgh
December 17th, 2002, 11:48 AM
thanks ,
i will try to save images and let you know.

Paresh