Photos, BLOBs and Images

  • I've just put myself in the Employees table in Northwind as an employee. MSSQL Server 2K. How do I add my photograph?

  • Don't know if anything is included with the Northwind sample. To add any kind of Blob in the database, you need to use the WRITETEXT or UPDATETEXT statements (see BOL for more info).

    Don't know how you would pass in your picture using this. Easiest way would be to write a simple VB/ASP/... app that uses ADO to set the value. Tons of references around on the net.

  • ADO is a lot easier, look for references to the ADO Stream object. Old way was getchunk/appendchunk (in ADO).

    Andy

    http://www.sqlservercentral.com/columnists/awarren/

  • Use textcopy. Textcopy utility is not described in SQL Server Books Online, but you

    can get its description by typing textcopy /? from the command prompt.

    The field that the photo is going into can not be null when you use textcopy.

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply