March 17, 2014 at 2:29 pm
Hello folks,
I need to create a StoredProc who will load a jpeg image from the hard drive and return it to a remote SQL Server. I have found several examples of code to store images in a varbinary data column in ASP, but I don't need to store the image, just load it in a varbinary and return the result, all within the SP.
can someone help me on this please??
thanks a lot for your time and help
March 17, 2014 at 3:00 pm
Dominic Gagné (3/17/2014)
Hello folks,I need to create a StoredProc who will load a jpeg image from the hard drive and return it to a remote SQL Server. I have found several examples of code to store images in a varbinary data column in ASP, but I don't need to store the image, just load it in a varbinary and return the result, all within the SP.
can someone help me on this please??
thanks a lot for your time and help
Just select the column.
select [YourVarBinaryColumn]
from YourTable
There is no way to have a stored procedure return an actual image. You need to convert this in whatever your front end is that is consuming the data.
_______________________________________________________________
Need help? Help us help you.
Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.
Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.
Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply