]> git.koha-community.org Git - koha.git/commit
Bug 5458: increase ccode column to varchar 80
authorFridolin Somers <fridolin.somers@biblibre.com>
Tue, 4 Sep 2018 08:40:29 +0000 (10:40 +0200)
committerFridolin Somers <fridolin.somers@biblibre.com>
Wed, 3 Oct 2018 13:15:18 +0000 (15:15 +0200)
commitba07e93035829f6763a94bb7320d1648db3c7005
treec2afb6774fdafc187608b411f58ba336d9461e02
parentbfe2a30c8b7aba539be9c9bec5b18062a5d56825
Bug 5458: increase ccode column to varchar 80

Koha allows you to define an authorised value having length 80, but then you
can't use it.

Here is why:
The SQL field items.ccode is a varchar(10).
The SQL field authorised_values.authorised_value is a varchar(80).
Therefore the authorised value is truncated to length 10 in items.ccode and the mapping from authorised value to description string fails in Koha.

This patch increases ccode column to varchar 80, like location.

Test plan :
1) Dont apply patches
2) Check there is on item field a subfield with authorised value category CCODE
3) Check this subfield is linked with database column items.ccode
4) Create an authorised values in category CCODE with 'DOCUMENTATION'
5) Edit an item on ccode and choose 'DOCUMENTATION'
6) Save item
7) Look at items.ccode in database or export in MARCXML
8) The value is troncated to 'DOCUMENTAT'
9) Apply patches and update database with installer/data/mysql/atomicupdate/bug_5458.sql
10) Repeate step 5 to 7
11) The value is not truncated 'DOCUMENTATION'

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
(cherry picked from commit c59ef0452ccbae17de3b839da4fa2c9f7f6b2e6f)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
(cherry picked from commit 892492cbda442564a33b1abdf374d43c024de22c)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
installer/data/mysql/atomicupdate/bug_5458.sql [new file with mode: 0644]
installer/data/mysql/kohastructure.sql