Bug 22782

Summary: Schema change for SocialData
Product: Koha Reporter: Nick Clemens (kidclamp) <nick>
Component: DatabaseAssignee: Bugs List <koha-bugs>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low CC: jonathan.druart, kyle, martin.renvoize, tomascohen
Version: Main   
Hardware: All   
OS: All   
See Also: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22096
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
19.05.00, 18.11.06
Circulation function:
Attachments: Bug 22782: DBIC update for SocialData

Description Nick Clemens (kidclamp) 2019-04-26 12:12:12 UTC
If you regenerate the schema on stretch you get a change to SocialData

I haven't committed it because I didn't kow where it came from, I don't believe it will affect anything, but wanted to document the change at the least

To recreate:
On debian 9 run misc/devel/update_dbix_class_files.pl
(devbox or koha testing docker just do dbic)
Note the change
Verify all works with this change
Comment 1 Jonathan Druart 2019-04-26 22:05:01 UTC
*** Bug 22096 has been marked as a duplicate of this bug. ***
Comment 2 Jonathan Druart 2019-04-26 22:06:50 UTC
My bet would be a change in DBIx::Class::Schema::Loader, however I did not find it.

social_data.isbn is a varchar and used as PK, so cannot be NULL, I guess that's why it has a default ''.
Comment 3 Jonathan Druart 2019-04-26 22:07:50 UTC
Also note that "show create table" will display the NOT NULL constraint:

  `isbn` varchar(30) COLLATE utf8mb4_unicode_ci NOT NULL,

It looks safe to commit, and better to fix the kohastructure.sql as well.
Comment 4 Nick Clemens (kidclamp) 2019-05-10 12:17:45 UTC
Created attachment 89539 [details] [review]
Bug 22782: DBIC update for SocialData
Comment 5 Nick Clemens (kidclamp) 2019-05-10 12:18:26 UTC
Trivial, just leaving here for reference
Comment 6 Nick Clemens (kidclamp) 2019-05-10 12:25:18 UTC
Awesome work all!

Pushed to master for 19.05
Comment 7 Martin Renvoize (ashimema) 2019-05-17 13:30:52 UTC
Pushed to 18.11.x for 18.11.06