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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

read image data with tsql

Status
Not open for further replies.

TWillard

Programmer
Apr 26, 2001
263
US
I am working with the sharepoint database. The docs table has a column titled MetaInfo. It is of type image. Its contents are xml files that store the metadata information about the doucment. I would like to create a procedure that queries this column and extracts the contants into a pre-defined table for better report generation. Is there a way to read the contents of the image column using just tsql? I think that I already know the answer. This is a sql 2000 instance, so the clr is not an option. My other thought is to use c# or vb.net to read in the xml file parse the contents and then insert into the database. I was just curious, if this could be done with just tsql reading the image contents and using tsql substrings to parse the xml.
 
Unfortunately no. T-SQL and SQL server cannot translate images.

Books Online said:
Data in an image data is stored as a string of bits and is not interpreted by SQL Server. Any interpretation of the data in an image column must be made by the application. For example, an application could store data in an image column using a BMP, TIFF, GIF, or JPEG format. The application that reads the data from the image column must recognize the format of the data and display it correctly. All an image column does is provide a location to store the stream of bits that make up the image data value.



Catadmin - MCDBA, MCSA
"No, no. Yes. No, I tried that. Yes, both ways. No, I don't know. No again. Are there any more questions?"
-- Xena, "Been There, Done That"
 
NP. Wish I had better news.



Catadmin - MCDBA, MCSA
"No, no. Yes. No, I tried that. Yes, both ways. No, I don't know. No again. Are there any more questions?"
-- Xena, "Been There, Done That"
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top