5 sub { rec('A') . rec('B') },
6 sub { config ('input collection') . rec('000') }
15 marc_leader('05','n');
17 ## LDR 06 - a - language material
18 marc_leader('06','a');
20 ## LDR 07 - Bibliographic level
21 # izvuci podatke iz tablie (za po i sf)
27 sub { rec('B') . rec('A') },
28 sub { config ('input collection') . rec('000') }
31 #if ( rec('225','a') ) {
32 # marc_leader('07','d');
34 # marc_leader('07','s');
38 marc_leader('07', $ldr7 );
42 ## LDR 17 - Encoding level ; 7 - minimal level, u - unknown
43 marc_leader('17','u');
46 marc_leader('18','i');
49 ## LDR 19 - Multipart resource record level ; # - Not specified or not applicable, a - Set, b - Part with independent title, c - Part with dependent title
52 ### 008 - All materials
54 marc_fixed('008','00', '010101'); # 00-05 - Date entered on file
56 ## za 008 06 treba i lookup u tablicu gdje postoji podatak o tome jel tekuci casopis ili nije?
57 ## c - Continuing resource currently published
58 ## d - Continuing resource ceased publication
59 ## u - Continuing resource status unknown
61 marc_fixed('008','06','|');
66 if ( rec('210','d') ) {
67 if ( rec ('210','d') =~ m#(\d{4}).*?-.*?(\d{4})# ) {
70 marc_fixed('008','06','d');
72 if ( rec ('210','d') =~ m{(\d{4}).*?-\s*$} ) {
75 marc_fixed('008','06','c');
78 marc_fixed('008','07', $d1);
79 marc_fixed('008','11', $d2);
83 marc_fixed('008','15', # 15-17 - Place of publication, production, or execution
87 marc_fixed('008','35',
88 first( lc(rec('101')) ) # 35-37 - Language
91 marc_fixed('008','38','|'); # 38 - Modified record
92 marc_fixed('008','39','d'); # 39 - Cataloging source
94 ### 008 - Continuing resources
98 $fre = ( rec('326') eq '2g' ) ? 'g' :
99 ( rec('326') eq 'g1' ) ? 'a' :
100 ( rec('326') eq 'g2' ) ? 'f' :
101 ( rec('326') eq 'g3' ) ? 't' :
102 ( rec('326') eq 'g4' ) ? 'q' :
103 ( rec('326') eq 'g5' ) ? 'z' :
104 ( rec('326') eq 'g6' ) ? 'b' :
105 ( rec('326') eq 'g8' ) ? 'b' :
106 ( rec('326') eq 'g9' ) ? 'm' :
107 ( rec('326') eq 'm1' ) ? 'm' :
108 ( rec('326') eq '10' ) ? 'm' :
109 ( rec('326') eq '11' ) ? 'm' :
110 ( rec('326') eq 'm2' ) ? 's' :
111 ( rec('326') eq '19' ) ? 's' :
112 ( rec('326') eq '20' ) ? 's' :
113 ( rec('326') eq '24' ) ? 's' :
114 ( rec('326') eq '26' ) ? 's' :
115 ( rec('326') eq 'm3' ) ? 'j' :
116 ( rec('326') eq 't1' ) ? 'w' :
117 ( rec('326') eq 't2' ) ? 'c' :
118 ( rec('326') eq 't2us' ) ? 'c' :
119 ( rec('326') eq 'nr' ) ? ' ' :
120 ( rec('326') eq 'np' ) ? 'u' :
123 marc_fixed('008','18', $fre); # 18 - Frequency - ovo treba popuniti iz polja 326
124 marc_fixed('008','19', '|'); # 19 - Regularity
125 # 20 - Undefined, ontains a blank (#) or fill character (|)
126 # za polje 008 21 treba lookup u tablicu s kodovima za sf i po, za ostale nadopuniti naknadno
132 sub { rec('B') . rec('A') },
133 sub { config ('input collection') . rec('000') }
137 marc_fixed('008','21', $stype); # 21 - Type of continuing resource
139 # 22 - Form of original item - blank
141 marc_fixed('008','24','|'); # 24 - Nature of entire work
142 marc_fixed('008','25','|||'); # 25-27 - Nature of contents
143 # 28 - Government publication
144 marc_fixed('008','29','|'); # 29 - Conference publication
146 marc_fixed('008','33','|'); # 33 - Original alphabet or script of title
147 marc_fixed('008','34','0'); # 34 - Entry convention
151 #if ( ! rec('225','a') ) {
164 config('input name'),
170 marc('035','a', $id);
174 # treba utvrditi točnu oznaku za ustanovu
192 #### 041 - indikatori
195 #marc_indicators('041', 0, ' ');
199 #marc_repeatable_subfield('041','a',
213 # marc_indicators('210', '1',' ');
215 ### 210 - ABBREVIATED TITLE
216 # pronaći prikladan izvor podataka (nsk baza, issn baza)
219 # drugi indikator prema clanu
221 marc_indicators('222',' ','0');
224 # pronaci prikadan izvor podataka - nsk baza, issn baze
234 # sub { rec('530','a') },
236 # sub { rec('011','a') },
243 # generiraju se prema clanu, trebalo bi możda i prema jeziku (jezika nema uvijek).
244 # potrebna naknadna kontrola
250 sub { rec('A') . rec('B') },
251 sub { config ('input collection') . rec('000') }
254 marc_indicators('245', 0, 0);
256 if ( ( $naslov =~ m/^Die /) ||
257 ( $naslov =~ m/^Das /) ||
258 ( $naslov =~ m/^Der /) ||
259 ( $naslov =~ m/^Les /) ||
260 ( $naslov =~ m/^The /) ) {
261 marc_indicators('245', 0, 4);
265 if ( ( $naslov =~ m/^Un /) ||
266 ( $naslov =~ m/^An /) ||
267 ( $naslov =~ m/^La /) ||
268 ( $naslov =~ m/^Le /) ||
269 ( $naslov =~ m/^Il /) ) {
270 marc_indicators('245', 0, 3);
273 if ( ( $naslov =~ m/^A /) ||
274 ( $naslov =~ m/^L'/) ) {
275 marc_indicators('245', 0, 2);
284 $c = $2 if $naslov =~ s{(\s+/)\s+(.+)$}{$1};
285 if ( $naslov =~ s{^(.+?[:=])\s+}{} ) {
292 #warn "a: $a\nb: $b\nc: $c\n";
294 $a = $a . '.' if ( ! ( $b || $c) );
295 $b = $b . '.' if ( ! $c && $b ) ;
298 marc('245','b', $b) if $b;
308 # prema jeziku - provjera
310 #if ( ( rec('200','a') =~ m/^Die /) ||
311 # ( rec('200','a') =~ m/^Das /) ||
312 # ( rec('200','a') =~ m/^The /) ) {
313 # marc_indicators('246', 0, 4);
315 # marc_indicators('246', 0, 0);
319 # povuci podatke iz prikladnog izvora (nsk, issn)
320 # 532 iz ISIS-a nije konvertirano
328 # sub { rec('532','a') },
330 # sub { rec('011','a') },
339 # provjeriti interpunkcije !!, u NSK nesto ne stima
341 marc_original_order('260','210');
345 # marc_repeatable_subfield('260','a',
347 # sub { rec('210','a') },
349 # sub { rec('011','a') },
353 # marc_repeatable_subfield('260','b',
355 # sub { rec('210','c') },
357 # sub { rec('011','a') },
363 # sub { rec('210','d') },
365 # sub { rec('011','a') },
370 # marc_original_order('260', '210');
378 ( rec('215','a') && rec('215','c') ) ? ' : ' :
379 ( rec('215','a') && rec('215','d') ) ? ' ; ' :
380 ( rec('215','a') && rec('215','e') ) ? ' + ' :
388 ( rec('215','c') && rec('215','d') ) ? ' ; ' :
389 ( rec('215','c') && rec('215','e') ) ? ' + ' :
397 rec('215','e') ? ' + ' :
407 ### 310 - current stated publication frequency
408 # potrebno ujednaciti, koristi se i u polju 008
414 ### 321 - former frequency of either an item or an update to an item when a current frequency is contained in field 310
417 # ovo bi trebalo procitati iz NSK konvertiranih podataka
420 marc_indicators('362', 0, ' ');
432 # sub { rec('207','a') },
434 # sub { first( rec('011','a') ) },
443 marc_indicators('490', '0', ' ');
477 # sub { rec('110','a'), },
479 # sub { rec('011','a') },
497 # koje podatke povuci iz drugih baza?
504 ### 534 - napomena o pretisku
510 ## potencijalno za izvuci iz NSK
514 # sub { rec('302','a') },
516 # sub { rec('011','a') },
523 # sub { rec('314','a') },
525 # sub { rec('011','a') },
532 # sub { rec('320','a') },
534 # sub { rec('011','a') },
542 ## sub { rec('316','a') },
544 ## sub { rec('011','a') },
545 ## sub { rec('11') },
551 marc_indicators('653', 0, ' ');
559 # marc_indicators('655', ' ', 4);
562 # sub { rec('608','a') },
564 # sub { rec('011','a') },
574 marc_indicators('700', 1, ' ');
594 marc_indicators('710', '2', ' ');
603 marc_indicators('770', 0, ' ');
611 marc_indicators('772', 0, ' ');
620 #if ( rec('225','a') ) {
622 #marc_indicators('773', 0, ' ');
625 ## da li je bitan redoslijed potpolja?
629 # sub { rec('000') },
631 # sub { rec('200','a') },
645 marc_indicators('777', 0, ' ');
655 marc_indicators('780', 0, 0);
664 marc_indicators('785', 0, 0);
696 # sub { rec('200','a') },
698 # sub { rec('200','a'), },
699 # sub { rec('225','a'), }
707 # sub { rec('001') },
709 # sub { rec('011','a') },
718 # sub { rec('001') },
720 # sub { first(rec('200','a')) . first(rec('200','e')) },
721 # sub { rec('200','a') . rec('200','e') },
729 # sub { rec('001') },
731 # sub { first(rec('200','a')) },
732 # sub { rec('200','a') },