/[webpac]/trunk/isis_sf.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Annotation of /trunk/isis_sf.pm

Parent Directory Parent Directory | Revision Log Revision Log


Revision 62 - (hide annotations)
Fri Jul 4 20:11:48 2003 UTC (16 years, 2 months ago) by dpavlin
File size: 560 byte(s)
added MARC file import

1 dpavlin 10 #
2 dpavlin 62 # get_sf($isis_row,'isis_field'[,'subfield'])
3 dpavlin 10 #
4 dpavlin 62 # e.g. get_sf($row,'700','a')
5 dpavlin 10 #
6 dpavlin 62 sub get_sf {
7 dpavlin 10 my $row = shift @_;
8     my $isis_id = shift @_;
9     my $subfield = shift @_;
10    
11 dpavlin 29 my $i = shift @_ || 0;
12    
13     my $out;
14    
15     if ($row->{$isis_id}->[$i]) {
16 dpavlin 45 if (! $subfield) {
17 dpavlin 10 # subfield list undef, empty or no defined subfields for this record
18 dpavlin 29 my $all_sf = $row->{$isis_id}->[$i];
19     $all_sf =~ s/\^./ /g; # nuke definitions
20     return $all_sf;
21 dpavlin 45 }
22     my $sf = OpenIsis::subfields($row->{$isis_id}->[$i]);
23     if ($sf->{$subfield}) {
24 dpavlin 10 return $sf->{$subfield};
25     }
26     }
27     }
28    
29     1;
30    

Properties

Name Value
cvs2svn:cvs-rev 1.4

  ViewVC Help
Powered by ViewVC 1.1.26