| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
| |||
| |||
| Hi Everyone, Using Vo2Ado with VO2.8, I need to get the contents of an XML field in SQL Server 2005 as a string. Here is the Select : SELECT myfield.query('*') AS xmlfield FROM mytable This Select is working : I use it in a DB Tool (DBVisualizer) and the tool show me automatically the data of the field as a string but when I execute this Select in VO, I cannot get the data as a string. I tried to cast in varchar (SELECT CAST(myfield.query('*') AS VARCHAR) AS xmlfield FROM mytable) but I get the following error : Target string size is too small to represent the XML instance Any help will be very appreciated. Cheers, -- Phil Mermod Crystal Reports Library for Visual Objects http://www.pkl.ch/dev/ |
|
#2
| |||
| |||
| Hi Phil, On 26 Aug 2008, at 15:38:45 [GMT GMT] (which was 17:38 where I live) you wrote about: 'VO2ADO : XML field (SQL Server)' > Using Vo2Ado with VO2.8, I need to get the contents of an XML > field in SQL Server 2005 as a string. > Here is the Select : SELECT myfield.query('*') AS xmlfield FROM > mytable > This Select is working : I use it in a DB Tool (DBVisualizer) > and the tool show me automatically the data of the field as a > string but when I execute this Select in VO, I cannot get the > data as a string. > I tried to cast in varchar (SELECT CAST(myfield.query('*') AS > VARCHAR) AS xmlfield FROM mytable) but I get the following error > : Target string size is too small to represent the XML instance > Any help will be very appreciated. XML Data is usually retrieved through an AdoStream object. Look at: http://www.extremeexperts.com/SQL/Ar...ithSQLXML.aspx and http://microsoft.apress.com/asptoday...2000-using-ado and http://www.alleged.org.uk/pdc/2003/10/08.html -- Robert van der Hulst AKA Mr. Data Vo2Jet & Vo2Ado Support VO & Vulcan.NET Development Team www.heliks.nl |
![]() |
| Thread Tools | |
| Display Modes | |
In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.