How get Xml Output using e Sql query first of all write sql query

SqlToXmlQuery.JPG


And Xml Output looks like this under below

xmlData2.JPG