Is there any tool or open source code to convert the sql queries [not the query results] to xml.
Example : if i have a sq开发者_Python百科l query like select * from employee where empname='jon'
. I want to generate this query in xml format like
<root>
<selectclause>
<field table=''....>
</selectclause>
</root>
Any plugins or open source code links are needed.
I am using SQL Server & need to extend to MySQL Databases also. However, i code for .Net Framework 4 in C#
select Customer_ID, Short_Name, Phone, Area,
sum(case when DATEDIFF(dd,Invoice_Date,GETDATE()) <= 21 then Balance end) '21 days',
sum(case when DATEDIFF(dd,Invoice_Date,GETDATE()) > 21 then Balance end) 'More than 21 days',
'' Visted, '' DLI, '' Collection
from vw_pending_invoice
where route = 1
group by Customer_ID, Short_Name, Phone, Area
精彩评论