Bug 12059: Prefer to list fields in the query
authorJonathan Druart <jonathan.druart@biblibre.com>
Thu, 4 Dec 2014 15:05:34 +0000 (16:05 +0100)
committerMason James <mtj@kohaaloha.com>
Sun, 18 Jan 2015 00:28:25 +0000 (13:28 +1300)
To avoir further issue, it's better to explicitely list the fields we
want to retrieve.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Mason James <mtj@kohaaloha.com>

C4/Acquisition.pm

index c6993c3..7e3bb1f 100644 (file)
@@ -2734,7 +2734,11 @@ sub GetInvoiceDetails {
     my $invoice = $sth->fetchrow_hashref;
 
     $query = q{
-        SELECT aqorders.*, biblio.*, biblioitems.*, aqbasket.basketname
+        SELECT aqorders.*, biblio.*,
+        biblio.copyrightdate,
+        biblioitems.publishercode,
+        biblioitems.publicationyear,
+        aqbasket.basketname
         FROM aqorders
           LEFT JOIN aqbasket ON aqorders.basketno = aqbasket.basketno
           LEFT JOIN biblio ON aqorders.biblionumber = biblio.biblionumber