@@ -, +, @@ --- etc/zebradb/marc_defs/unimarc/biblios/record.abs | 15 +- .../mandatory/unimarc_framework_DEFAULT.sql | 154 ++++++------------- 2 files changed, 57 insertions(+), 112 deletions(-) --- a/etc/zebradb/marc_defs/unimarc/biblios/record.abs +++ a/etc/zebradb/marc_defs/unimarc/biblios/record.abs @@ -326,12 +326,13 @@ melm 995$a homebranch,Host-item,item melm 995$b homebranch,Host-item,item melm 995$c holdingbranch,Record-Source,item melm 995$d holdingbranch,Record-Source,item -melm 995$e location,item +melm 995$e location,item melm 995$f barcode,item -melm 995$h ccode,item -melm 995$j LC-card-number:s,item -melm 995$k Call-Number,Local-Classification,lcn,Call-Number:p,Local-Classification:p,lcn:p,item -melm 995$s popularity:n,popularity:s,item -melm 995$n onloan:d,onloan:n,onloan:s,onloan:w,item -melm 995$u Note,Note:p,item +melm 995$8 ccode,item +melm 995$k Call-Number,Local-Classification,lcn,Call-Number:p,Local-Classification:p,lcn:p,item +melm 995$n onloan:d,onloan:n,onloan:s,onloan:w,item +melm 995$u Note,Note:p,item melm 995 item # just to index every subfield + +### 942 local info +melm 942$0 popularity:n,popularity:s,item --- a/installer/data/mysql/en/marcflavour/unimarc/mandatory/unimarc_framework_DEFAULT.sql +++ a/installer/data/mysql/en/marcflavour/unimarc/mandatory/unimarc_framework_DEFAULT.sql @@ -20,6 +20,13 @@ -- 2000. It includes the changes published in Update 3." - -- http://www.ifla.org/VI/3/p1996-1/sec-uni.htm . -- 2006-03-15 a + +-- From Zeno Tajoli (2010-08-12): +-- +-- Improved default id Koha field (090) and koha date field (099). +-- Insert link to sql coloum biblio.biblionumber in tag 001 +-- Insert the use of 942, local data +-- Insert a standard minimun on 995 (holding field) -- *********************************************************************** @@ -49,46 +56,47 @@ -- ****************************************************** --- Current Record ID Field/Subfields +-- Current Record ID Field/Subfields (090) -INSERT INTO `marc_tag_structure` (`tagfield`, `liblibrarian`, `libopac`, `repeatable`, `mandatory`, `authorised_value`, `frameworkcode`) VALUES - ('999', 'System Control Numbers (Koha)', 'System Control Numbers (Koha)', 0, 0, '', ''); +insert into `marc_tag_structure`(`tagfield`,`liblibrarian`,`libopac`,`repeatable`,`mandatory`,`authorised_value`,`frameworkcode`) +values + ('090','System Control Numbers (Koha)','System Control Numbers (Koha)',0,0,'',''); -INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`, `libopac`, `repeatable`, `mandatory`, `kohafield`, `tab`, `authorised_value`, `authtypecode`, `value_builder`, `isurl`, `hidden`, `frameworkcode`, `seealso`, `link`, `defaultvalue`) VALUES - ('999', '9', 'Koha biblio number (autogenerated)', 'Koha biblio number', 0, 0, 'biblio.biblionumber', -1, '', '', '', 0, -5, '', '', '', NULL), - ('999', 'a', 'Koha biblioitem number (autogenerated)', 'Koha biblioitem number', 0, 0, 'biblioitems.biblioitemnumber', -1, '', '', '', 0, -5, '', '', '', NULL); +insert into `marc_subfield_structure`(`tagfield`,`tagsubfield`,`liblibrarian`,`libopac`,`repeatable`,`mandatory`,`kohafield`, +`tab`,`authorised_value`,`authtypecode`,`value_builder`,`isurl`,`hidden`,`frameworkcode`,`seealso`,`link`,`defaultvalue`) +values + ('090','a','Koha biblioitem number (autogenerated)','Koha biblioitem number (autogenerated)',0,0,'biblioitems.biblioitemnumber', +9,'','','',0,-5,'',NULL,'',''); +-- Local date field/Subfields (099) --- ****************************************************** +insert into `marc_tag_structure`(`tagfield`,`liblibrarian`,`libopac`,`repeatable`,`mandatory`,`authorised_value`,`frameworkcode`) +values + ('099','local dates','',0,0,'',''); +insert into `marc_subfield_structure`(`tagfield`,`tagsubfield`,`liblibrarian`,`libopac`,`repeatable`,`mandatory`,`kohafield`,`tab`,`authorised_value`,`authtypecode`,`value_builder`, +`isurl`,`hidden`,`frameworkcode`,`seealso`,`link`,`defaultvalue`) +values + ('099','c','Date of creation (bib. record)','Date of creation (bib. record)',0,0,'biblio.datecreated',0,'','','',0,-5,'',NULL,'',''); --- Plugins which need to be written for primary biblioitems Field/Subfields. +insert into `marc_subfield_structure`(`tagfield`,`tagsubfield`,`liblibrarian`,`libopac`,`repeatable`,`mandatory`,`kohafield`,`tab`,`authorised_value`,`authtypecode`,`value_builder`, +`isurl`,`hidden`,`frameworkcode`,`seealso`,`link`,`defaultvalue`) +values + ('099','d','Last modified date (bib. record)','Last modified data (bib. record)',0,0,'biblio.timestamp',0,'','','',0,-5,'',NULL,'',''); --- ('990', 'h', 'Classification part', 'Classification part', 0, 0, 'biblioitems.cn_class', 9, '', '', 'unimarc_callnumber.pl', NULL, 0, '', '', '', NULL), +++ @@ -112,59 +120,7 @@ INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian` --- Recommended items Field/Subfields - --- INSERT INTO `marc_tag_structure` (`tagfield`, `liblibrarian`, `libopac`, `repeatable`, `mandatory`, `authorised_value`, `frameworkcode`) VALUES --- ('995', 'k', 'Call number (full call number)', 'Call number (full call number)', 0, 0, 'items.itemcallnumber', 10, '', '', 'unimarc_itemcallnumber.pl', 0, 0, '', '', '', NULL), +++ @@ -172,41 +128,29 @@ INSERT INTO `marc_tag_structure` (`tagfield`, `liblibrarian`, `libopac`, `repeat INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`, `libopac`, `repeatable`, `mandatory`, `kohafield`, `tab`, `authorised_value`, `authtypecode`, `value_builder`, `isurl`, `hidden`, `frameworkcode`, `seealso`, `link`, `defaultvalue`) VALUES ('995', '0', 'Withdrawn status', 'Withdrawn status', 0, 0, 'items.wthdrawn', 10, 'WTHDRAWN', '', '', 0, 0, '', '', '', NULL), - ('995', '1', 'Lost status', 'Lost status', 0, 0, 'items.itemlost', 10, 'LOST', '', '', 0, 0, '', '', '', NULL), - ('995', '2', 'System code (specific classification or other scheme and edition)', 'System code (specific classification or other scheme and edition)', 0, 0, '', 10, '', '', '', NULL, 0, '', '', '', NULL), + ('995', '2', 'Lost status', 'Lost status', 0, 0, 'items.itemlost', 10, 'LOST', '', '', 0, 0, '', '', '', NULL), ('995', '3', 'Use restrictions', 'Use restrictions', 0, 0, 'items.restricted', 10, 'RESTRICTED', '', '', 0, 0, '', '', '', NULL), - ('995', '4', 'Koha normalized classification for sorting', 'Koha normalized classification for sorting', 0, 0, 'items.cn_sort', -1, '', '', '', 0, 7, '', '', '', NULL), - ('995', '5', 'Coded location qualifier', 'Coded location qualifier', 0, 0, '', 10, '', '', 'marc21_locationqualifier.pl', NULL, 0, '', '', '', NULL), + ('995', '5', 'Date acquired', 'Coded location qualifier', 0, 0, 'items.dateaccessioned + ', 10, '', '', '', NULL, 0, '', '', '', NULL), ('995', '6', 'Copy number', 'Copy number', 0, 0, 'items.copynumber', 10, '', '', '', NULL, 0, '', '', '', NULL), ('995', '7', 'Uniform Resource Identifier', 'Uniform Resource Identifier', 0, 0, 'items.uri', 10, '', '', '', 0, 0, '', '', '', NULL), ('995', '8', 'Koha collection', 'Koha collection', 0, 0, 'items.ccode', 10, 'CCODE', '', '', 0, 0, '', '', '', NULL), ('995', '9', 'Internal item number (Koha itemnumber, autogenerated)', 'Internal itemnumber (Koha itemnumber)', 0, 0, 'items.itemnumber', -1, '', '', '', 0, -5, '', '', '', NULL), - ('995', 'a', 'Origin of the item (home branch) (free text)', 'Origin of item (home branch) (free text)', 0, 1, 'items.homebranch', 10, 'branches', '', '', 0, 0, '', '', '', NULL), - ('995', 'b', 'Origin of item (home branch) (coded)', 'Origin of item (home branch (coded)', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'c', 'Lending or holding organisation (holding branch) (free text)', 'Lending or holding organisation (holding branch) (free text)', 0, 1, 'items.holdingbranch', 10, 'branches', '', '', 0, 0, '', '', '', NULL), - ('995', 'd', 'Lending or holding organisation (holding branch) code', 'Lending or holding organisation (holding branch) code', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'e', 'Genre detail', 'Genre', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), + ('995', 'a', 'Origin of the item (home branch) (free text)', 'Origin of item (home branch) (free text)', 0, 1, '', 10, '', '', '', 0, 0, '', '', '', NULL), + ('995', 'b', 'Origin of item (home branch) (coded)', 'Origin of item (home branch (coded)', 0, 0, 'items.homebranch', 10, 'branches', '', '', 0, -1, '', '', '', NULL), + ('995', 'c', 'Lending or holding organisation (holding branch) code', 'Lending or holding organisation (holding branch) code ', 0, 1, 'items.holdingbranch', 10, 'branches', '', '', 0, 0, '', '', '', NULL), + ('995', 'd', 'Lending or holding organisation (holding branch) (free text)', 'Lending or holding organisation (holding branch) (free text)', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), + ('995', 'e', 'Shelving location', 'Shelving location', 0, 0, 'items.location', 10, 'LOC', '', '', 0, 0, '', '', '', NULL), ('995', 'f', 'Barcode', 'Barcode', 0, 0, 'items.barcode', 10, '', '', 'barcode.pl', 0, 0, '', '', '', NULL), - ('995', 'g', 'Barcode prefix', 'Barcode prefix', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'h', 'Barcode incrementation', 'Barcode incrementation', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'i', 'Barcode suffix', 'Barcode suffix', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'j', 'Section', 'Section', 0, 0, '', 10, '', '', '', 0, 0, '', '', '', NULL), + ('995', 'j', 'Inventory number', 'Inventory number', 0, 0, 'items.stocknumber ', 10, '', '', '', 0, 0, '', '', '', NULL), ('995', 'k', 'Call number (full call number)', 'Call number (full call number)', 0, 0, 'items.itemcallnumber', 10, '', '', '', 0, 0, '', '', '', NULL), ('995', 'l', 'Numbering (volume or other part)', 'Numbering (bound volume or other part)', 0, 0, 'items.materials', 10, '', '', '', 0, 0, '', '', '', NULL), ('995', 'm', 'Date of loan or deposit', 'Date of loan or deposit', 0, 0, 'items.datelastborrowed', 10, '', '', '', 0, -5, '', '', '', NULL), - ('995', 'n', 'Expiration of loan date', 'Expiration of loan date', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), + ('995', 'n', 'Expiration of loan date', 'Expiration of loan date', 0, 0, 'items.onloan', 10, '', '', '', 0, -1, '', '', '', NULL), ('995', 'o', 'Circulation type (not for loan)', 'Circulation type (not for loan)', 0, 0, 'items.notforloan', 10, '', '', '', 0, 0, '', '', '', NULL), - ('995', 'p', 'Serial', 'Serial', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'q', 'Intended audience (age level)', 'Intended audience (age level)', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'r', 'Type of item and material', 'Type of item and material', 0, 1, '', 10, '', '', '', 0, 0, '', '', '', NULL), - ('995', 's', 'Acquisition mode', 'Acquisition mode', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 't', 'Genre', 'Genre', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), + ('995', 'r', 'Type of item and material', 'Type of item and material', 0, 1, 'items.itype', 10, 'itemtypes', '', '', 0, 0, '', '', '', NULL), ('995', 'u', 'Copy note', 'Copy note', 0, 0, 'items.itemnotes', 10, '', '', '', 0, 0, '', '', '', NULL), - ('995', 'v', 'Periodical number', 'Periodical number', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'w', 'Recipient organisation code', 'Recipient organisation code', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'x', 'Recipient organisation, free text', 'Recipient organisation, free text', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'y', 'Recipient parent organisation code', 'Recipient parent organisation code', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL), - ('995', 'z', 'Recipient parent organisation, free text', 'Recipient parent organisation, free text', 0, 0, '', 10, '', '', '', 0, -1, '', '', '', NULL); + ('995', 'v', 'Serial Enumeration / chronology', 'Serial Enumeration / chronology', 0, 0, 'items.enumchron', 10, '', '', '', 0, -1, '', '', '', NULL); @@ -385,7 +329,7 @@ INSERT INTO `marc_tag_structure` (`tagfield`, `liblibrarian`, `libopac`, `repeat INSERT INTO `marc_subfield_structure` (`tagfield`, `tagsubfield`, `liblibrarian`, `libopac`, `repeatable`, `mandatory`, `kohafield`, `tab`, `authorised_value`, `authtypecode`, `value_builder`, `isurl`, `hidden`, `frameworkcode`, `seealso`, `link`, `defaultvalue`) VALUES ('000', '@', 'fixed length control field', 'fixed length control field', 0, 1, '', 0, '', '', 'unimarc_leader.pl', 0, 0, '', '', '', NULL), - ('001', '@', 'control field', 'control field', 0, 1, '', 0, '', '', '', 0, 0, '', '', '', NULL), + ('001', '@', 'control field', 'control field', 0, 1, 'biblio.biblionumber', -1, '', '', '', 0, 0, '', '', '', NULL), ('005', '@', 'control field', 'control field', 0, 0, '', 0, '', '', 'marc21_field_005.pl', 0, 0, '', '', '', NULL), ('010', 'a', 'Number (ISBN)', 'Number (ISBN)', 0, 0, 'biblioitems.isbn', 0, '', '', '', 0, 0, '', '', '', NULL), ('010', 'b', 'Qualification', 'Qualification', 0, 0, '', 0, '', '', '', 0, 0, '', '', '', NULL), --