Bug 24640: Allow quotes.timestamp to be NULL
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Wed, 12 Feb 2020 11:26:25 +0000 (12:26 +0100)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Wed, 19 Feb 2020 10:59:17 +0000 (10:59 +0000)
commit9446b894b863fd3db0dbc22536895a4ef754ca7e
treebc82f50cb268d52d1eb7d764c777ba7b6530e007
parent79dbd633695527d3a6d6e5bd8327fd3c26f2f639
Bug 24640: Allow quotes.timestamp to be NULL

It is broken with strict mode enable, timestamp is created without
default value.

Note that the .sql installer file init the value with NOW(), which is
wrong.

DBD::mysql::st execute failed: Field 'timestamp' doesn't have a default
value [for Statement "INSERT INTO quotes (source, text) VALUES (?, ?);"
with ParamValues: 0="poeut", 1="pouet"] at
/kohadevbox/koha/tools/quotes/quotes_ajax.pl line 49.

Test plan:
Create a new quote of the day
=> Without this patch you will get an error

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
installer/data/mysql/atomicupdate/bug_24640.perl [new file with mode: 0644]
installer/data/mysql/kohastructure.sql