From 7ecb690e7ca471c0e01cc82529052b49c8715e41 Mon Sep 17 00:00:00 2001 From: Rogan Hamby Date: Mon, 20 Feb 2017 14:11:18 -0500 Subject: [PATCH] LP#1665626: adding new records to the meta group and breaking into new file Signed-off-by: Rogan Hamby Signed-off-by: Ben Shum --- Open-ILS/tests/datasets/sql/assets_mr.sql | 28 +++++++++++++++++++++++ Open-ILS/tests/datasets/sql/bibs_mr.sql | 12 ++++++++++ Open-ILS/tests/datasets/sql/load_all.sql | 11 ++++++++- 3 files changed, 50 insertions(+), 1 deletion(-) create mode 100644 Open-ILS/tests/datasets/sql/assets_mr.sql create mode 100644 Open-ILS/tests/datasets/sql/bibs_mr.sql diff --git a/Open-ILS/tests/datasets/sql/assets_mr.sql b/Open-ILS/tests/datasets/sql/assets_mr.sql new file mode 100644 index 0000000000..2fafd63a1b --- /dev/null +++ b/Open-ILS/tests/datasets/sql/assets_mr.sql @@ -0,0 +1,28 @@ +-- Create call numbers +SELECT evergreen.populate_call_number(4, 'MR ', 'IMPORT MR', NULL); -- BR1 +SELECT evergreen.populate_call_number(5, 'MR ', 'IMPORT MR', NULL); -- BR2 +SELECT evergreen.populate_call_number(6, 'MR ', 'IMPORT MR', NULL); -- BR3 +SELECT evergreen.populate_call_number(7, 'MR ', 'IMPORT MR', NULL); -- BR4 +SELECT evergreen.populate_call_number(9, 'MR ', 'IMPORT MR', NULL); -- BM1 + +-- Create copies +SELECT evergreen.populate_copy(4, 4, 'MR40000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(5, 5, 'MR50000', 'MR'); -- BR2 +SELECT evergreen.populate_copy(6, 6, 'MR60000', 'MR'); -- BR3 +SELECT evergreen.populate_copy(7, 7, 'MR70000', 'MR'); -- BR4 +SELECT evergreen.populate_copy(9, 9, 'MR90000', 'MR'); -- BM1 + +SELECT evergreen.populate_copy(4, 4, 'MR41000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(4, 4, 'MR42000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(4, 4, 'MR43000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(4, 4, 'MR44000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(4, 4, 'MR45000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(4, 4, 'MR46000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(4, 4, 'MR47000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(4, 4, 'MR48000', 'MR'); -- BR1 +SELECT evergreen.populate_copy(4, 4, 'MR49000', 'MR'); -- BR1 + +SELECT evergreen.populate_copy(5, 5, 'MR51000', 'MR'); -- BR2 +SELECT evergreen.populate_copy(6, 6, 'MR61000', 'MR'); -- BR3 +SELECT evergreen.populate_copy(7, 7, 'MR71000', 'MR'); -- BR4 +SELECT evergreen.populate_copy(9, 9, 'MR91000', 'MR'); -- BM1 diff --git a/Open-ILS/tests/datasets/sql/bibs_mr.sql b/Open-ILS/tests/datasets/sql/bibs_mr.sql new file mode 100644 index 0000000000..04f4895349 --- /dev/null +++ b/Open-ILS/tests/datasets/sql/bibs_mr.sql @@ -0,0 +1,12 @@ +\set bib_tag '''IMPORT MR''' + +INSERT INTO marcxml_import (tag, marc) VALUES + +(:bib_tag,'00918nim a22002535 4500283853420131130185904.0sd|uungnnmmneu130904 eng 9781482926323 (CMD)$19.951482926326 (CMD)$19.95Blackstone Audio Inc, Special Markets Po Box 969, Ashland, OR, USA, 97520, (541)4886035SAN 173-2811UtOrBLW813813.0000Lovecraft, H. P./ Herrmann, Edward (NRT)At the Mountains of Madness[sound recording].[Place of publication not identified] :Blackstone Audio Inc,2013.spoken wordrdacontentaudiordamediaaudio discrdacarrier'), +(:bib_tag,'01423pam a2200373 a 4500307956520080108231100.0080108s2005 nyu b 001 1 eng 2005-0415550812974417 (pbk.) :$15.95(DLC)2005041555DLCDLCDLCt------813/.5222FLOVECRAFTLovecraft, H. P.(Howard Phillips),1890-1937.At the mountains of madness /H.P. Lovecraft ; introduction by China Mie ville.Definitive ed.New York :Modern Library,2005.xxv, 186 p. ;20 cm.MARCIVE 12/19/07Includes bibliographical references (p. xxiv-xxv) and index.At the mountains of madness -- Supernatural horror in literature.FossilsCollection and preservationFiction.Scientific expeditionsFiction.Supernatural in literature.Stone carvingFiction.AntarcticaFiction.Fantasy fiction.gsafdHorror fiction.gsafdLovecraft, H. P.(Howard Phillips),1890-1937.Supernatural horror in literature.'), +(:bib_tag,'01639nim a2200445 a 4500410133920140714090509.0sd fungnnmmned140709s2012 tnunnnn f n eng d9781843795940DD10435Recorded Books(CtWfDGI)rdd90010435CtWfDGIengCtWfDGIt------PS3523.O833A96 2012b813/.5223VLOVEAMMR 35Lovecraft, H. P.(Howard Phillips),1890-1937.At the mountains of madness[sound recording] /H.P. Lovecraft.Unabridged.Franklin, TN :Naxos AudioBooks ;Prince Frederick, MD :Distributed by Recorded Books,p2012.4 sound discs (5 hr.) :digital ;4 3/4 in.Title from container.Compact disc.In container (17 cm.).Read by William Roberts.An old man consents to a radio interview and a number of terrible truths are revealed about an expedition of Antarctica in the 1920's where everyone died horribly.Scientific expeditionsFiction.Stone carvingFiction.Supernatural in literature.FossilsCollection and preservationFiction.AntarcticaFiction.Horror fiction.gsafdFantasy fiction.gsafdAudiobooks.lcgftRoberts, William,1943-nrtNaxos AudioBooks, Ltd.Recorded Books, LLC.'), +(:bib_tag,'01132cam a2200337Ka 4500940380020170130113807.0160622s2017 nyu d 000 1 eng d(OCoLC)952384050BTCTAengBTCTABDXTEFBTOCLCOOCLCFTEFBT97815247556141524755613HQBA813/.623LPCLINECline, Ernest.Ready player one /Ernest Cline.[New York] :Random House Large Print,[2017]608 p. (large print) ;24 cm.Regression (Civilization)Fiction.Virtual realityFiction.Shared virtual environmentsFiction.UtopiasFiction.PuzzlesFiction.Large type books.Fantasy fiction.gsafdB&T'); +(:bib_tag,'01817cim a2200481 i 4500920638120120814110343.0m h cr una||||||||sz usnnnn|||ed111201s2011 nyunnnn o || eng d9780307913166 (electronic audio bk.)(TLC)erc0000004936(OCoLC)749998216F9F9D65D-C3C8-445C-AE9D-D82B72C241D0OverDrive, Inc.http://www.overdrive.comTLCTLCTLCrdaPS3603.L548R43 2011813/.622Cline, Ernest,author.Ready player one[electronic resource] /Ernest Cline.New York :Crown Publishers©20111 sound file :digitalspoken wordspwrdacontentcomputercrdamediaonline resourcecrrdacarrieraudio filerdaeAudiobooktlcgtGeneraltlctargetElectronic audio file.Electronic reproduction.New YorkPenguin Random House Audio Publishing Group2011Available via World Wide Web.Regression (Civilization)Fiction.Virtual realityFiction.UtopiasFiction.PuzzlesFiction.Fantasy fiction.gsafdElectronic audio books.localOverDrive, Inc.,distributor.'); +(:bib_tag,'01619cam a2200409Ia 4500915027420120530113527.0sd fungnnmmned110523s2011 mdu e 000 1 eng d9780307970060 :40.00030797006X :40.00RHA3179Books on Tape3760223(OCoLC)7267535993760223Books on Tapehttp://library.booksontape.comTEFBTTEFBTTEFBTPS3603.L548R43 2011ab813/.623BCD ClineCline, ErnestReady player one /Ernest Cline.[sound recording] Unabridged sound recording[Westminster, Md.] :Books on Tape,p2011.13 sound discs ; 15 hours, 41 minutes :digital ;4 3/4 in.Unabridged.Read by Wil Wheaton.At once wildly original and stuffed with irresistible nostalgia, READY PLAYER ONE is a spectacularly genre-busting, ambitious, and charming debut-- part quest novel, part love story, and part virtual space opera set in a universe where spell-slinging mages battle giant Japanese robots, entire planets are inspired by Blade Runner, and flying DeLoreans achieve light speed.Regression (Civilization)Fiction.Virtual realityFiction.UtopiasFiction.PuzzlesFiction.Audiobooks.Fantasy fiction'); +(:bib_tag,'00975pam a2200337 a 4500811262820110823130500.0110422s2011 nyu 000 1 eng 20110152479780307887436 :$24.00030788743X :$24.00(DLC) 2011015247DLCDLCNjBwBTGCmBTpccPS3603.L548R43 2011813/.622Cline, Ernest.Ready player one /Ernest Cline.1st ed.New York :Crown Publishers,c2011.374 p. ;25 cm.Regression (Civilization)Fiction.Virtual realityFiction.UtopiasFiction.PuzzlesFiction.Fantasy fiction.gsafd1') +; diff --git a/Open-ILS/tests/datasets/sql/load_all.sql b/Open-ILS/tests/datasets/sql/load_all.sql index 50ea078d50..821a7b5b84 100644 --- a/Open-ILS/tests/datasets/sql/load_all.sql +++ b/Open-ILS/tests/datasets/sql/load_all.sql @@ -1,4 +1,4 @@ -BEGIN; +N; -- stop on error \set ON_ERROR_STOP on @@ -30,6 +30,12 @@ BEGIN; -- load RDA bibs \i bibs_rda.sql +-- load EbookAPI bibs +\i bibs_ebook_api.sql + +-- load metarecord bibs +\i bibs_mr.sql + -- insert all loaded bibs into the biblio.record_entry in insert order INSERT INTO biblio.record_entry (marc, last_xact_id) SELECT marc, tag FROM marcxml_import ORDER BY id; @@ -49,6 +55,9 @@ INSERT INTO biblio.record_entry (marc, last_xact_id) -- load RDA copies, etc. \i assets_rda.sql +-- load MR copies, etc. +\i assets_mr.sql + -- load copy-related data \i assets_extras.sql -- 2.43.2