The answer to question 1 is, as Phil wrote is use a BLOB field. Depending on the size of the actual JPG (from my experience > 35kBytes - I have not done any extensive testing to determine how big a BLOB can be and I think it is written somewhere), you may have to use a MEDIUMBLOB field type...