[Koha-devel] Fail to migrate issuingrules from 19.05 to 20.05

Philippe Blouin philippe.blouin at inlibro.com
Tue Nov 3 21:48:20 CET 2020


Hello all,

Simple question: am I interpreting right that '*' itemtypes in 
issuingrules fail to migrate to circulation_rules because of the constraint?

DBD::mysql::db do failed: Cannot add or update a child row: a foreign 
key constraint fails (`koha_vingt`.`circulation_rules `, CONSTRAINT 
`circ_rules_ibfk_3` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` 
(`itemtype`) ON DELETE CASCADE ON UPDATE CASCADE) [for Statement "
                 INSERT INTO circulation_rules ( categorycode, 
branchcode, itemtype, rule_name, rule_value )
                 SELECT IF(categorycode='*', NULL, categorycode), 
IF(branchcode='*', NULL, branchcode), IF(itemtype='*', NULL, itemtype) , 
'finedays', COALESCE( finedays, '' )
                 FROM issuingrules
             "] at ./installer/data/mysql/updatedatabase.pl line 20712.

Migrating that DB can be long, so rather than re-test extensively, I 
figured I'd raise my hand and ask the community what I'm getting wrong.  
Migration goes from 19.05.04 to 20.05.04.

Thanks in advance,

-- 
Philippe Blouin,
Directeur de la technologie

Tél.  : (833) 465-4276, poste 230
philippe.blouin at inLibro.com <mailto:philippe.blouin at inLibro.com>

inLibro | pour esprit libre | www.inLibro.com <http://www.inLibro.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.koha-community.org/pipermail/koha-devel/attachments/20201103/441e4065/attachment-0001.htm>


More information about the Koha-devel mailing list