You have not iterated over the nodeset returned by $xp->find so you only get one value back. See the docs for XML::XPath for an example of how to do that (it's right in the synopsis so I'm surprised you missed it).
And if you want to dump an array, pass the reference to Dumper:
#!/usr/bin/env perl use strict; use warnings; use Data::Dumper; my @records = qw/a b c/; print "Array: " . Dumper @records; print "Array ref: " . Dumper \@records;
In reply to Re: not fetching correct records in xml output
by hippo
in thread not fetching correct records in xml output
by snehit.ar
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |