XML to Excel, help me with script

Joined
May 23, 2010
Messages
1
Reaction score
0
I know how to write script from mysql to excel but I don't know how to write this xml to excel:

Code:
 <?xml version="1.0" encoding="UTF-8" ?> 
- <!-- # wanstats 
  --> 
- <cacti>
- <report>
- <settings>
  <title>Wan_links</title> 
  <owner>Administrator (admin)</owner> 
  <template>wan_statistic</template> 
  <start>2010-04-03</start> 
  <end>2010-04-09</end> 
  <last_run>2010-04-10 22:34:05</last_run> 
  </settings>
- <variables>
- <variable>
  <id>3</id> 
  <name>over90percent</name> 
  <description>Your description</description> 
  <value>10</value> 
  <min_value>10</min_value> 
  <max_value>100</max_value> 
  </variable>
  </variables>
- <measurands>
- <measurand>
  <abbreviation>CAPA</abbreviation> 
  <description>kapacitet</description> 
  </measurand>
- <measurand>
  <abbreviation>CRIT</abbreviation> 
  <description>critical - time (%) more than 10% usage</description> 
  </measurand>
  </measurands>
- <data_items>
- <item>
  <description>MIAMI - wan546 - Gi1/0/8</description> 
  <subhead /> 
  <start_day>Monday</start_day> 
  <end_day>Sunday</end_day> 
  <start_time>00:00:00</start_time> 
  <end_time>24:00:00</end_time> 
  <time_zone>GMT</time_zone> 
- <results>
- <traffic_in>
  <krit measurand="KRIT" unit="%">0</krit> 
  </traffic_in>
- <traffic_out>
  <krit measurand="KRIT" unit="%">0</krit> 
  </traffic_out>
- <overall>
  <kapa measurand="KAPA" unit="Bits/s">5.76E+8</kapa> 
  </overall>
  </results>
  </item>
- <item>
  <description>LONDON[2] -  wan134_Gi4/1/0.10</description> 
  <subhead /> 
  <start_day>Monday</start_day> 
  <end_day>Sunday</end_day> 
  <start_time>00:00:00</start_time> 
  <end_time>24:00:00</end_time> 
  <time_zone>GMT</time_zone> 
- <results>
- <traffic_in>
  <krit measurand="KRIT" unit="%">0</krit> 
  </traffic_in>
- <traffic_out>
  <krit measurand="KRIT" unit="%">0</krit> 
  </traffic_out>
- <overall>
  <kapa measurand="KAPA" unit="Bits/s">32000000</kapa> 
  </overall>
  </results>
  </item>
  </data_items>
  </report>
  </cacti>


How can specify and write childs (bellow) to excel rows?

results->traffic_out->krit
results->traffic_out->pros
results->overall->kapa
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,995
Messages
2,570,230
Members
46,819
Latest member
masterdaster

Latest Threads

Top