Can't speak to MYSQL but in SQL Server you insert the file directly as
insert into Pictures (name,picture)
Values ('first pic',(select * from openrowset(bulk 'd:\temp\testpic.jpg',single_blob) as picture))
In this case my table is named Pictures and is defined as name=VARCHAR(50) and picture=VARBINARY(MAX)
The last parameter in the above example (picture) is the name of the column defined as VARBINARY(MAX)
Reverend Jim
Posting Shark
1,167 posts since Aug 2010
Reputation Points: 253
Solved Threads: 159