Retrieveing DB Values in XML Format using XML EXPLICIT

XML EXPLICIT


EXPLICIT enables you to to define each level of hierarchy and how each level is going to look. In order to define hierarchy, you create internally a table called universal table.


select 1 as Tag, NULL as Parent, EmployeeId as [Employee!1!EmployeeID], Notes as [Employee!1!cdata]
from Employees order by EmployeeID
for XML EXPLICIT


Output:




<Employee EmployeeID="1" cdata="Education includes a BA in psychology from Colorado State University in 1970. She also completed "The Art of the Cold Call." Nancy is a member of Toastmasters International."/><Employee EmployeeID="2" cdata="Andr


Comments

No responses found. Be the first to comment...


  • Do not include your name, "with regards" etc in the comment. Write detailed comment, relevant to the topic.
  • No HTML formatting and links to other web sites are allowed.
  • This is a strictly moderated site. Absolutely no spam allowed.
  • Name:
    Email: