Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SSIS and Import/Export (2005)
 import xml that is a string

Author  Topic 

magmo
Aged Yak Warrior

558 Posts

Posted - 2009-04-29 : 11:20:27
Hi

I have a string that have xml structure. I need to create a stored procedure that insert that string into a xml data type column + that I also want to add 1 Img parameters into a Img datatype column.

My table looks like this..

tbl_Files

ID Int
ImgFile Img
XmlFileContent xml


Can someone please show me how to accomplish this?

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2009-04-29 : 13:46:06
use varbinary(max) to store image info & xml data type to store xml info
Go to Top of Page

magmo
Aged Yak Warrior

558 Posts

Posted - 2009-04-29 : 14:16:30
Shouldn't I use Img type for images?
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2009-04-29 : 14:20:49
if you're using sql 2005 or above use varrbinary(max). image is deprecated from sql 2005 onwards
Go to Top of Page

magmo
Aged Yak Warrior

558 Posts

Posted - 2009-04-29 : 14:42:20
Ok, thanks for letting me know. I was not aware about that
Go to Top of Page
   

- Advertisement -