...that doesn't mean FOR XMLPATH doesn't work. FOR...Profile.ProfileID = Profile_EmailAddress.ProfileID FOR XMLPATH(''), TYPE) AS [EmailAddress] FROM...simple, stripped down, example. An XML document in the real world...C736-DB11-BFF0-000FFE41B09F' FOR XML AUTO, ROOT('TravelerProfiles'), ELEMENTS RESULTS...returningmultipleXML records instead of one record with multiplechildren...
... XML in SQL Server without using XML EXPLICIT, just like SQL 2000. ...extrememly simple, stripped down, example. An XML document in the real world is...82F81341-C736-DB11-BFF0-000FFE41B09F' FOR XML AUTO, ROOT('TravelerProfiles'), ELEMENTS RESULTS IN...is returningmultipleXML records instead of one record with multiplechildren ... read all the documentation on XMLPATH to no avail. Any ...
... '82F81341-C736-DB11-BFF0-000FFE41B09F' FOR XML AUTO, ROOT('TravelerProfiles'), ELEMENTS RESULTS IN...... is returningmultipleXML records instead of one record with multiplechildren when a joined table has more ...> </Profile> </Traveler> </TravelerProfiles> But instead it returns one record for each record ...I have read all the documentation on XMLPATH to no avail. Any help ...
... of SQL Server is receiveing and returning very complex XML data. Complex XML ....MasterProfileAttributeGroupID WHERE Person.PersonID = @PersonID FOR XMLPATH('TravelerProfile'), ELEMENTS for instance. ...then MS has again missed the XML boat. Either way, thanks for ... the relationships and render the xml correctly? I don't see ... data. In SQL 2000, the XML serialization of the results was ...
...necessary? Can't the query engine read the relationships and render the xml correctly? I don't see that a subquery is required for that...ON Profile.ProfileID = Profile_EmailAddress.ProfileID WHERE Person.PersonID = '82F81341-C736-DB11-BFF0-000FFE41B09F' FOR XMLPATH('TravelerProfiles') Make sense? Thanks, Kent Tegels, DevelopMentor http://staff.develop.com/ktegels/
... = Profile.ProfileID LEFT OUTER JOIN Profile_EmailAddress ON Profile.ProfileID = Profile_EmailAddress.ProfileID WHERE Person.PersonID = '82F81341-C736-DB11-BFF0-000FFE41B09F' FOR XMLPATH('TravelerProfiles') Make sense? Thanks, Kent Tegels, DevelopMentor http://staff.develop.com/ktegels/
...that is returningmultipleXML records instead of one record with multiplechildren when a joined table has more than...= '82F81341-C736-DB11-BFF0-000FFE41B09F' FOR XMLPATH('TravelerProfiles') It should return ...> </Profile> </Traveler> </TravelerProfiles> But instead it returns one record for each record ... have read all the documentation on XMLPATH to no avail. Any help ...
...that is returningmultipleXML records instead of one record with multiplechildren when a joined table has more than...= '82F81341-C736-DB11-BFF0-000FFE41B09F' FOR XMLPATH('TravelerProfiles') It should return ...> </Profile> </Traveler> </TravelerProfiles> But instead it returns one record for each record ... have read all the documentation on XMLPATH to no avail. Any help ...
....SalesOrderDetail s where s.productID = pp.productID for xml auto,type ) from production.product pp where pp.ProductSubcategoryID = pc.ProductCategoryID for xml auto,type ) from production.productCategory pc for xml auto,type So, sure, its not long as your example, but ... to sub-queries is that you're running multiple queries, it doesn't actually happen. If its ...
... the query engine read the relationships and render the xml correctly? I don't see that a subquery is ... you really want is nested data. In SQL 2000, the XML serialization of the results was done as a step after ... resultset generation as the output is an instance of the XML type (typically). SQL 2005 is able to insert XML instances into another XML instance, so this is how you do it...