-
Looking for a samaritan
I have a problem and hope someone can help.
I have an XML document and need to extract the data from it .
The ideal solution would be for the data within the XML to be extracted and inputed into a excell spreadsheet. As I receive several XML documents a day I would Ideally like each extraction to be added after the next ( ie I extract xml document A and it puts into a spreadsheet , then when I extract XML document B the data from then is extracted and added below the data from document A and so on).
I believe this should be pretty easy and simple for a coder , if anyone can write the needed code for me , I would be ever so gratefull as I don't know how to program. Any language would be fine.
If anyone is willing to give it a go then please PM me,
Thanks
-
Once again some more questions:
1. Do you want the entire document, or just parts of it? (fields)
2. Are the documents all of the same length and format?
3. Can you provide two examples.......they don't have to be real, just realistic as to data type (numeric, alpha, alphanumeric) and length/layout.
The solution might be as simple as just importing them into Excel/Access or writing an update query. Sometimes you can do this with just the native GUI, otherwise there is a bit of VBS "tuning" required (yeah, I know......redundant, but I didn't develop MS office :D)
-
last time I did anything to do with coding for XML I ended up using c#. It has some nice libraries for dealing with XML.
easiest output would just be to a CSV file, easy to append to and openable in excel. Of course, if you want to take this data and do excel stuff to it you can't save it in CSV format.
An easier option might be make something that converts your XML to CSV and then copy and paste to the bottom of your existing document.
</my two pence>
-
I've got an XML-to-CSV php class (for a virtually tabular XML format) floating around somewhere, along with a "combine CSVs" script. Would those help?
They're scars from fighting with a Multiple Listing Service data feed. At least it wasn't biomedical data. <shiver>
-
Here is a page with a VBS script that nearly does what you want. Warning I havn't tested the script so be carefull about using it. http://www.codeproject.com/vbscript/xml2csv.asp . I would sugest you check out microsoft script page for other examples if you want to go with VBS.
Cheers