Bugzilla – Attachment 163996 Details for
Bug 28869
Optionally restrict authorised values to tinyint
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28869: Database revision
Bug-28869-Database-revision.patch (text/plain), 1.98 KB, created by
Marcel de Rooy
on 2024-03-27 13:19:43 UTC
(
hide
)
Description:
Bug 28869: Database revision
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2024-03-27 13:19:43 UTC
Size:
1.98 KB
patch
obsolete
>From f9217ff72fd63de7b56f196f6c1adee34d3f016e Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Tue, 30 Jan 2024 14:08:09 +0000 >Subject: [PATCH] Bug 28869: Database revision >Content-Type: text/plain; charset=utf-8 > >Test plan: >Run updatedatabase.pl > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> >--- > installer/data/mysql/atomicupdate/bug_28869.pl | 17 +++++++++++++++++ > installer/data/mysql/kohastructure.sql | 1 + > 2 files changed, 18 insertions(+) > create mode 100755 installer/data/mysql/atomicupdate/bug_28869.pl > >diff --git a/installer/data/mysql/atomicupdate/bug_28869.pl b/installer/data/mysql/atomicupdate/bug_28869.pl >new file mode 100755 >index 0000000000..bf8b9136b3 >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_28869.pl >@@ -0,0 +1,17 @@ >+use Modern::Perl; >+ >+return { >+ bug_number => 28869, >+ description => "Add authorised_value_categories.is_integer_only", >+ up => sub { >+ my ($args) = @_; >+ my ( $dbh, $out ) = @$args{qw(dbh out)}; >+ if ( !column_exists( 'authorised_value_categories', 'is_integer_only' ) ) { >+ $dbh->do( >+ q{ >+ALTER TABLE authorised_value_categories ADD COLUMN is_integer_only tinyint(1) DEFAULT 0 NOT NULL >+ } >+ ); >+ } >+ }, >+}; >diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql >index ea540c0819..b4cbda7e97 100644 >--- a/installer/data/mysql/kohastructure.sql >+++ b/installer/data/mysql/kohastructure.sql >@@ -1008,6 +1008,7 @@ DROP TABLE IF EXISTS `authorised_value_categories`; > CREATE TABLE `authorised_value_categories` ( > `category_name` varchar(32) NOT NULL DEFAULT '', > `is_system` tinyint(1) DEFAULT 0, >+ `is_integer_only` tinyint(1) NOT NULL DEFAULT 0, > PRIMARY KEY (`category_name`) > ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; > /*!40101 SET character_set_client = @saved_cs_client */; >-- >2.30.2
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 28869
:
161745
|
161746
|
161747
|
161748
|
161749
|
162412
|
162413
|
162414
|
162415
|
162416
|
163996
|
163997
|
163998
|
163999
|
164000
|
164001
|
166697
|
166698
|
166699
|
166700
|
166701
|
166702
|
166906