Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

*need* to insert binary data into sql server image column

Status
Not open for further replies.

silverspecv

Programmer
Oct 31, 2003
125
US
I know all the pro's and con's, but this is not my database, so I am stuck with it. I have a hard drive full of .TIF files that must be inserted into an sql database in a column of type IMAGE. I have used cffile action=readbinary to read it, use tobase64() to convert it, but what is the syntax for getting it into sql server?
 
Have you found your answer ? I'm stucked with the same problem...
 
No, I never did find an answer.. it is apparently quite complicated.
 
Yeah, I saw that one, but the problem I had is that I was using a pre-existing database, so I could not change data types.. The example shown by Teknology specifies that he used datatype of TEXT, while I was stuck with data type IMAGE.. And of course using text will work, but then you are not really storing binary, and you have to use the tobase64 and tobinary to convert it to text and back. The real solution will store true binary. But if you are running your own database and really need to store "binaries" in the table, and you don't mind using datatype of text, then it should work fine.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top