Results of a Query are returned as an XML document.

vishalneeraj-24503
Posted by vishalneeraj-24503 under Sql Server category on | Points: 40 | Views : 386
We can use For XML Auto for the result:-
The FOR XML extension allows the creation of XML from relational data.

SELECT employee_id,employee_name,pan_number,ldap
FROM employee_master
FOR XML AUTO,ELEMENTS;


Elements:-Specifies that the columns are returned as sub-elements to the table element. Otherwise, they are mapped as attributes

Comments or Responses

Login to post response