Browse by Tags

All Tags » XQuery (RSS)
One of my friends approached me recently with a request to write a TSQL query that reads information from an RDF document. Here is the sample XML document he wanted to process. <RDF xmlns:r="http://www.w3.org/TR/RDF/" xmlns:d="http:...
One of my friends emailed me this morning asking help for reading data from Google Analytics Atom feed, using Query with TSQL. My friend sent me a sample XML document he obtained from Google Analytics and here is the query that reads information from...
We have seen a few examples that demonstrated how to delete elements and attributes from XML documents. In this lab, let us see how to delete rows from a table, based on the data in an XML document. DECLARE @t TABLE (id INT ) INSERT INTO @t(id) SELECT...
I was working on my presentation for 24-hour-pass event on 2nd September and came across the sorting issue with the solution explorer. I have a number of script demos and I wanted to organize them by name. No matter, what I did, the solution explorer...
Welcome to XQuery Lab 47. In this lab, we will see how to generate an HTML table from an XML document, using XQuery. Here is the source data: < CUST COMPANY ="Company1" CONTACT ="Jacob" /> < CUST COMPANY ="Company1"...
I just came across a task to extract ZIP code values from the address column of a table. The address is a single string that contains information such as street, city, state, zip code, apartment number etc. The data comes from a legacy system where the...
  XML Workshop - A series of XML articles published at www.sqlservercentral.com XML Workshop I - Generating XML with FOR XML - A short article that explains how to generate XML output with TSQL keyword FOR XML with AUTO and RAW directives XML Workshop...