Re: Extract XLM data from in Mathematica
- To: mathgroup at smc.vnet.net
- Subject: [mg125717] Re: Extract XLM data from in Mathematica
- From: Chris Degnen <degnen at cwgsy.net>
- Date: Fri, 30 Mar 2012 04:31:08 -0500 (EST)
- Delivered-to: l-mathgroup@mail-archive0.wolfram.com
- References: <jl150v$lcf$1@smc.vnet.net>
It looks more complicated than it is. I was able to do
everything I needed with just two commands. E.g.
retrievedXML = ImportString[XMLdataRecord, "XML",
"NormalizeWhitespace" -> False];
{numbers} = Cases[retrievedXML,
XMLElement["telephonenumbers", _, _],
Infinity] /. XMLElement[_, _, {val_}] :> val;
On Thursday, March 29, 2012 9:03:43 AM UTC+1, Murta wrote:
> Hi All
>
> I was trying to extract some data from a XML using Mathematica and
> I discovered that it's terribly complicated, with a lot of pattern
> inside pattern.
> I was using this reference to guide me:
> http://reference.wolfram.com/mathematica/XML/tutorial/TransformingXML.html
> There is some package to make life easier?
>
> tks in advance
> Murta