Viewing XML files as a table

Hey folks,

I tried to search on this but was thwarted by XML being three letters long. But if there are any XML gurus out there, I need help!

My company is migrating to a platform in which the primary method of file delivery for input will be XML. We used to work exclusively with SQL and it was easy to run reports to check imported data before we applied it to the database by running ad hoc reports, etc. Now we’re faced with XML files and as of yet none of us are savvy enough with XML to work with it effectively.

Basically, we have a program that spits out XML files from incoming flat files and we need to look at the incoming data to make sure the right info is in the right column. How can we view these XML files in a table format? Is there a tool out there that would let us do multi-dimensional reports on this data so we could see what we’re about to load to the DB? I’ve had a little success in bringing the XML files into Access and validating the data in there, but there’s got to be a better way.

Mods, if this isn’t the right forum for this, I apologize in advance!



What about actually making an HTML table out of the data using XSL and XMLHTTP? It should work if you’re running a Windows server.

Check out this article with a quick how-to.

If you write out the data to an HTML table with a border of 1 and/or cell bgcolors, you can see right away if the table gets fuxored when it writes out. Especially if you browse to it using, say, Netscape 6 (IE and the latest Mozillas are usually pretty easy going on bad table code).

As ZipperJJ mentions probably the best way to look at the files would be to use an XSL/T transform that outputs an HTML table.

Depending on the kind of fault you’re looking for you could even write a transform that would only flag up problem rows.

If your database is SQLServer 2000 you could try using the OPENXML statement to open the XML document as a table and check it there.

Without knowing the structure of your XML documents and exactly what you’re trying to achieve I can’t really offer more advice than this. My email’s in my profile though if you want to discuss it further.