NAME

Catmandu::Fix::pica_map - copy pica values of one field to a new field

SYNOPSIS

   # Copy from field 021A all subfields to field dc_title
   pica_map(021A, dc_title);

   # Copy from field 021A subfield a to field dc_title
   pica_map(021Aa, dc_title);

   # Copy from field 021A subfield a and d to field dc_title and join them 
   pica_map(021Aad, dc_title, join:' / ');

   # Copy from field 021A subfield d and a in given order to field dc_title 
   pica_map(021Ada, dc_title, pluck:1);

   # Copy from field 021A subfield a and d to field dc_title and append them to an array
   pica_map(021Ada, dc_title.$append);

   # Copy from field 021A all subfields to field dc_title and split them to an array
   pica_map(021Ada, dc_title, split:1);

   # Copy from all fields 005A all subfields to field bibo_issn and split them to an array of arrays
   pica_map(005A, bibo_issn, split:1, nested_arrays:1);

   # Copy from field 144Z with occurrence 01 subfield a to dc_subject
   pica_map('144Z[01]a','dc_subject');

SEE ALSO

See PICA::Path for a definition of PICA path expressions and mapping rules or test files for more examples. See PICA::Data for more methods to process parsed PICA+ records.