Bug 22648

Summary: Typo in SQL in smart-rules.pl
Product: Koha Reporter: Nick Clemens <nick>
Component: CirculationAssignee: Katrin Fischer <katrin.fischer>
Status: CLOSED FIXED QA Contact: Martin Renvoize <martin.renvoize>
Severity: major    
Priority: P5 - low CC: gmcharlt, katrin.fischer, kyle.m.hall, martin.renvoize
Version: 18.11   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
18.11.05
Attachments: Bug 22648: Fix typo in SQL in smart-rules.pl
Bug 22648: Fix typo in SQL in smart-rules.pl

Description Nick Clemens 2019-04-05 16:59:41 UTC
Trailing comma in the update statement

 349             my $sth_update = $dbh->prepare(q|
 350                 UPDATE default_borrower_circ_rules
 351                 SET maxissueqty = ?,
 352                     maxonsiteissueqty = ?,
 353                 WHERE categorycode = ?
 354             |);
Comment 1 Katrin Fischer 2019-04-06 10:22:12 UTC
Created attachment 87469 [details] [review]
Bug 22648: Fix typo in SQL in smart-rules.pl

Fixes 2 SQL statements for setting the maximum
number of checkouts possible.

To test:
- In 18.11
- Verify that setting Default checkout, hold and return policy works
- Verfiy that setting Default checkout, ohld and return policy by
  patron category works
Comment 2 Katrin Fischer 2019-04-06 10:29:45 UTC
Just did some testing in our 18.11 installation and it doesn't blow up?
Comment 3 Martin Renvoize 2019-04-08 08:51:55 UTC
I 'think' this is only an issue if you're running in SQL strict modes.. it'll be a nice thing to fix, but hopefully in the wild it's not really causing any problems.
Comment 4 Martin Renvoize 2019-04-08 08:54:34 UTC
Created attachment 87489 [details] [review]
Bug 22648: Fix typo in SQL in smart-rules.pl

Fixes 2 SQL statements for setting the maximum
number of checkouts possible.

To test:
- In 18.11
- Verify that setting Default checkout, hold and return policy works
- Verfiy that setting Default checkout, ohld and return policy by
  patron category works

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 5 Martin Renvoize 2019-04-08 08:54:55 UTC
Signing off.
Comment 6 Martin Renvoize 2019-04-08 08:55:52 UTC
Going straight for PQA as it's a trivial patch.. thanks for reporting Nick and thanks for the quick patch Katrin.
Comment 7 Martin Renvoize 2019-04-08 08:57:44 UTC
Pushed to 18.11.x for 18.11.05.