in reply to XML::Generator loop
XML::Simple is not simple! In this case it may be better to hand roll the inner block of XML that is causing you grief. Something based on the following perhaps?
use warnings; use strict; my @rows = ( {label=>'January', value=>'17400'}, #... {label=>'December', value=>'39800'}, ); print "<set label='$_->{label}' value='$_->{value}' />\n" for @rows;
Prints:
<set label='January' value='17400' /> <set label='December' value='39800' />
If you need entity handling or other XML generation help then you would be better to use one of the modules designed for generating XML such as XML::Writer.
|
|---|