Thank you very much for your help.
When I use pipes :
assuming ('code' and 'title' are in the first node and 'url' in the second one)
......
my $sth = $dbh->prepare(qq{INSERT INTO books VALUES (?, ?, ?)});
foreach my $row ($xp->findnodes('/Ensemble/item/Attributes | Ensemble/item/SubInfo '))...