Bugzilla – Attachment 89391 Details for
Bug 22812
Cannot add new subscription with strict SQL modes turned on
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 22812: Fix new subscription with strict sql modes
Bug-22812-Fix-new-subscription-with-strict-sql-mod.patch (text/plain), 990 bytes, created by
Jonathan Druart
on 2019-05-06 18:36:33 UTC
(
hide
)
Description:
Bug 22812: Fix new subscription with strict sql modes
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2019-05-06 18:36:33 UTC
Size:
990 bytes
patch
obsolete
>From 9031702e159af14eccbb46cd660beb6dad9ab493 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 6 May 2019 13:34:19 -0500 >Subject: [PATCH] Bug 22812: Fix new subscription with strict sql modes > >With sql_strict_modes turned on, if you try to create a new subscription >you will get: >Incorrect integer value: '' for column '$INT_COLUMN' at row 1 >--- > C4/Serials.pm | 5 +++++ > 1 file changed, 5 insertions(+) > >diff --git a/C4/Serials.pm b/C4/Serials.pm >index f8c17b9189..1f5a87091e 100644 >--- a/C4/Serials.pm >+++ b/C4/Serials.pm >@@ -1373,6 +1373,11 @@ sub NewSubscription { > ) = @_; > my $dbh = C4::Context->dbh; > >+ $_ ||= undef # Set to undef for integer values, not empty string >+ for ( >+ $aqbooksellerid, $lastvalue1, $innerloop1, $lastvalue2, >+ $innerloop2, $lastvalue3, $innerloop3, >+ ); > #save subscription (insert into database) > my $query = qq| > INSERT INTO subscription >-- >2.11.0
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 22812
:
89391
|
89392
|
89393
|
89454
|
89455
|
89456
|
89535
|
89536
|
89537
|
89561
|
89570
|
89571
|
89572
|
89573
|
89590
|
89591
|
89592
|
89593