[Koha-bugs] [Bug 34494] Table tmp_holdsqueue fails to be created for MySQL 8

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Aug 15 09:06:12 CEST 2023


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34494

Victor Grousset/tuxayo <victor at tuxayo.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #154317|0                           |1
        is obsolete|                            |

--- Comment #4 from Victor Grousset/tuxayo <victor at tuxayo.net> ---
Created attachment 154417
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=154417&action=edit
Bug 34494: Table tmp_holdsqueue fails to be created for MySQL 8

It appears that MySQL 8 rejects creating any table where the primary key is
nullable. The table tmp_holdsqueue has a nullable pk ( itemnumber ) but there
is no reason for this column to be nullable ( generating a holds queue entry
with no itemnumber is not possible ) so it make sense to just remove the
nullability for MySQL compatiability.

Test Plan:
1) Using MySQL 8.0, attempt to create a database from kohastructure.sql
   If you use ktd, you can try:  DB_IMAGE=mysql:8.0 ktd up
2) Note the failure to create the table
3) Apply this patch
4) Repeat step 1
5) The table is created!

Signed-off-by: David Nind <david at davidnind.com>
Signed-off-by: Victor Grousset/tuxayo <victor at tuxayo.net>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list