my ( $xmlFile ) = $ARGV[0]; my ( $xs1 ) = XML::Simple->new(); my ( $message ) = $xs1->XMLin( $xmlFile, KeyAttr => [], ForceArray => [ 'StructuredNote', 'ItemDetail', 'ItemDetail->StructuredNote' ] );