Bugzilla – Attachment 54845 Details for
Bug 10455
remove redundant 'biblioitems.marc' field
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10455: Remove biblioitems.marc
Bug-10455-Remove-biblioitemsmarc.patch (text/plain), 4.37 KB, created by
Jonathan Druart
on 2016-08-25 09:30:24 UTC
(
hide
)
Description:
Bug 10455: Remove biblioitems.marc
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2016-08-25 09:30:24 UTC
Size:
4.37 KB
patch
obsolete
>From 1b191847bf8d9dfdf0abb6e60c4dcb3077a1aa4e Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Thu, 25 Aug 2016 10:01:59 +0100 >Subject: [PATCH] Bug 10455: Remove biblioitems.marc > >Any discussions about biblioitems.marc bring to the same conclusion: >This field is useless and should be removed. >We are storing MARC data into 2 different fields, that does not make >sense. > >Test plan: >Add / update / export / import /delete records >should work as before >--- > C4/Biblio.pm | 10 +++++----- > C4/Items.pm | 4 ++-- > C4/Overdues.pm | 3 +-- > 3 files changed, 8 insertions(+), 9 deletions(-) > >diff --git a/C4/Biblio.pm b/C4/Biblio.pm >index 2798325..2f0093e 100644 >--- a/C4/Biblio.pm >+++ b/C4/Biblio.pm >@@ -159,7 +159,7 @@ Biblio.pm contains functions for managing storage and editing of bibliographic d > > =item 2. as raw MARC in the Zebra index and storage engine > >-=item 3. as raw MARC the biblioitems.marc and biblioitems.marcxml >+=item 3. as MARC XML in biblioitems.marcxml > > =back > >@@ -183,7 +183,7 @@ Because of this design choice, the process of managing storage and editing is a > > =item 2. _koha_* - low-level internal functions for managing the koha tables > >-=item 3. Marc management function : as the MARC record is stored in biblioitems.marc(xml), some subs dedicated to it's management are in this package. They should be used only internally by Biblio.pm, the only official entry points being AddBiblio, AddItem, ModBiblio, ModItem. >+=item 3. Marc management function : as the MARC record is stored in biblioitems.marcxml, some subs dedicated to it's management are in this package. They should be used only internally by Biblio.pm, the only official entry points being AddBiblio, AddItem, ModBiblio, ModItem. > > =item 4. Zebra functions used to update the Zebra index > >@@ -211,7 +211,7 @@ When dealing with items, we must : > > =item 2. add the itemnumber to the item MARC field > >-=item 3. overwrite the MARC record (with the added item) into biblioitems.marc(xml) >+=item 3. overwrite the MARC record (with the added item) into biblioitems.marcxml > > When modifying a biblio or an item, the behaviour is quite similar. > >@@ -232,8 +232,8 @@ framework code. > This function also accepts a third, optional argument: a hashref > to additional options. The only defined option is C<defer_marc_save>, > which if present and mapped to a true value, causes C<AddBiblio> >-to omit the call to save the MARC in C<bibilioitems.marc> >-and C<biblioitems.marcxml> This option is provided B<only> >+to omit the call to save the MARC in C<bibilioitems.marcxml> >+This option is provided B<only> > for the use of scripts such as C<bulkmarcimport.pl> that may need > to do some manipulation of the MARC record for item parsing before > saving it and which cannot afford the performance hit of saving >diff --git a/C4/Items.pm b/C4/Items.pm >index 81a8263..a47f1b1 100644 >--- a/C4/Items.pm >+++ b/C4/Items.pm >@@ -327,8 +327,8 @@ embedded item fields. This routine is suitable for batch jobs. > > This API assumes that the bib record has already been > saved to the C<biblio> and C<biblioitems> tables. It does >-not expect that C<biblioitems.marc> and C<biblioitems.marcxml> >-are populated, but it will do so via a call to ModBibiloMarc. >+not expect that C<biblioitems.marcxml> are populated, but it >+will do so via a call to ModBibiloMarc. > > The goal of this API is to have a similar effect to using AddBiblio > and AddItems in succession, but without inefficient repeated >diff --git a/C4/Overdues.pm b/C4/Overdues.pm >index 71c8606..a42d746 100644 >--- a/C4/Overdues.pm >+++ b/C4/Overdues.pm >@@ -159,7 +159,7 @@ Returns a count and a list of overdueitems for a given borrowernumber > > sub checkoverdues { > my $borrowernumber = shift or return; >- # don't select biblioitems.marc or biblioitems.marcxml... too slow on large systems >+ # don't select biblioitems.marcxml... too slow on large systems > my $sth = C4::Context->dbh->prepare( > "SELECT biblio.*, items.*, issues.*, > biblioitems.volume, >@@ -196,7 +196,6 @@ sub checkoverdues { > WHERE issues.borrowernumber = ? > AND issues.date_due < NOW()" > ); >- # FIXME: SELECT * across 4 tables? do we really need the marc AND marcxml blobs?? > $sth->execute($borrowernumber); > my $results = $sth->fetchall_arrayref({}); > return ( scalar(@$results), $results); # returning the count and the results is silly >-- >2.8.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 10455
:
54844
|
54845
|
54846
|
54847
|
54849
|
54850
|
54855
|
54856
|
54857
|
54858
|
54859
|
54860
|
54875
|
54881
|
55401
|
55402
|
55403
|
55404
|
55405
|
55406
|
55407
|
55408
|
55409
|
55410
|
55844
|
55845
|
55846
|
55847
|
55848
|
55849
|
55850
|
55851
|
55852
|
55853