madasafish
Technical User
Code:
<configuration>MediacastCarousel_abc_dynamic<variable>^M^M
<name>Cdf.PollingInterval</name>^M^M
<value>60</value>^M^M
<type>string</type>^M^M
<grouplevel>3</grouplevel>^M^M
<permission>0</permission>^M^M
<groupname>ngetv1</groupname>^M^M
</variable>^M^M
<variable>^M^M
<name>Cdf.Url</name>^M^M
<value>[URL unfurl="true"]http://dcabwww.mh.abc.co.uk/bridge/shared/cdfs/bridge_shared_langley.cdf</value>^M^M[/URL]
<type>string</type>^M^M
<grouplevel>3</grouplevel>^M^M
<permission>0</permission>^M^M
<groupname>ngetv1</groupname>^M^M
</variable>^M^M
<variable>^M^M
<name>PhysicalNetworkAddress</name>^M^M
<value>65535:7501:64</value>^M^M
<type>string</type>^M^M
<grouplevel>3</grouplevel>^M^M
<permission>0</permission>^M^M
<groupname>ngetv1</groupname>^M^M
</variable>^M^M
......
the <variable> stansa repeats with different name,value,type,grouplevel,permission values.
until we reach......
</variable>
</configuration>
Then repeats with a new configuration
<configuration>MediacastCarousel_cht_dynamic<variable>^M^M
......etc....
</variable>
</configuration>
What I want to achieve is the following...
Name,Pol_Int,PNA,URL
abc_dynamic,60,65535:7501:64,cht_dynamic,etc,etc,etc
Currently I am using MS Excell to convert the xml file to csv format. Even this does not give the exact result wanted and does require some massaging after the conversion.
I have also looked at Expat and xgawk, I did manage to acheive some output with xgawk but not the desired output.
Any help or better ideas appreciated,
Thanks in advance,
Madasafish