-
Covert SQL Table into XML
Hi,
We have a Table called PCMessages. We are not using SQL Server. We are using MSDE.
Code = Varchar(25) - Primary Key, Unique
Message = Varchar(300)
Type = Numeric(15)
Caution = Varchar(300)
Action = Varchar(300)
Additional_Info = Varchar(300)
I want to convert the SQL Table into XML format as shown below using SQL Query. I dont know how to do it. I have used
FOR XML AUTO, ELEMENTS but I cant see the proper output.
<Pactus>
<Module name="Customer">
<code value="CSTACC0001">
<message value="Customer account business name cannot be null for Organization Account"/>
<type value="critical"/>
<action value="If the customer account type is Organization please enter a valid business name"/>
<additionalInformation value="/>
</code>
</Module>
</Pactus>
Hope I can get a solution
Thanks and regards
Rajesh
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks