Bug 12752 has fixed a bug for installations upgrading from 3.14, but has not fixed the problem for new installations. Because of some wrong data manipulations, the names for a given letter code may diverge. In particular OVERDUE and PREDUE names of phone notices have been wrongly modify by bug 11867.
Created attachment 49997 [details] [review] Bug 16217: Resync names of notices Bug 12752 has fixed a bug for installations upgrading from 3.14, but has not fixed the problem for new installations. Because of some wrong data manipulations, the names for a given letter code may diverge. In particular OVERDUE and PREDUE names of phone notices have been wrongly modify by bug 11867: they have been set to the name of the first HOLD notice. Trying to be back on our feet, this update DB entry will try to guess and set back up the correct name. To know if your install is affected by this bug, the following SQL query can help you: SELECT code, name, message_transport_type FROM letter WHERE code="PREDUE" OR code="OVERDUE"; If the names are different for the same code, something went wrong. Executing this update DB entry should fix the divergence.
Comment on attachment 49997 [details] [review] Bug 16217: Resync names of notices Review of attachment 49997 [details] [review]: ----------------------------------------------------------------- ::: installer/data/mysql/updatedatabase.pl @@ +12211,4 @@ > SetVersion($DBversion); > } > > +$DBversion = "XXX"; Atomic update .perl instead?
Created attachment 50388 [details] [review] Bug 16217: Resync names of notices Bug 12752 has fixed a bug for installations upgrading from 3.14, but has not fixed the problem for new installations. Because of some wrong data manipulations, the names for a given letter code may diverge. In particular OVERDUE and PREDUE names of phone notices have been wrongly modify by bug 11867: they have been set to the name of the first HOLD notice. Trying to be back on our feet, this update DB entry will try to guess and set back up the correct name. To know if your install is affected by this bug, the following SQL query can help you: SELECT code, name, message_transport_type FROM letter WHERE code="PREDUE" OR code="OVERDUE"; If the names are different for the same code, something went wrong. Executing this update DB entry should fix the divergence.
(In reply to M. Tompsett from comment #2) > > Atomic update .perl instead? I think it's needed. Currently it does not apply
Created attachment 50722 [details] [review] Bug 16217: Resync names of notices Bug 12752 has fixed a bug for installations upgrading from 3.14, but has not fixed the problem for new installations. Because of some wrong data manipulations, the names for a given letter code may diverge. In particular OVERDUE and PREDUE names of phone notices have been wrongly modify by bug 11867: they have been set to the name of the first HOLD notice. Trying to be back on our feet, this update DB entry will try to guess and set back up the correct name. To know if your install is affected by this bug, the following SQL query can help you: SELECT code, name, message_transport_type FROM letter WHERE code="PREDUE" OR code="OVERDUE"; If the names are different for the same code, something went wrong. Executing this update DB entry should fix the divergence.
Now applies but... I run insert into letter select module,code,branchcode,'New advance name',is_html,title,content,'print' from letter where code = 'PREDUE' Then SELECT code, name, message_transport_type from letter WHERE code='PREDUE' OR code='OVERDUE' gives +--------+----------------------------+------------------------+ | code | name | message_transport_type | +--------+----------------------------+------------------------+ | PREDUE | Advance Notice of Item Due | email | | PREDUE | New advance name | print | +--------+----------------------------+------------------------+ This is the case we are trying to fix, isn't it? Running perl installer/data/mysql/updatedatabase.pl DEV atomic update: bug_16217.perl does not fix this. Am I doing the right test?
Created attachment 50736 [details] [review] Bug 16217: Resync names of notices Bug 12752 has fixed a bug for installations upgrading from 3.14, but has not fixed the problem for new installations. Because of some wrong data manipulations, the names for a given letter code may diverge. In particular OVERDUE and PREDUE names of phone notices have been wrongly modify by bug 11867: they have been set to the name of the first HOLD notice. Trying to be back on our feet, this update DB entry will try to guess and set back up the correct name. To know if your install is affected by this bug, the following SQL query can help you: SELECT code, name, message_transport_type FROM letter WHERE code="PREDUE" OR code="OVERDUE"; If the names are different for the same code, something went wrong. Executing this update DB entry should fix the divergence.
Sorry, my $dbh = C4::Context->dbh was missing in the .perl file.
Created attachment 50751 [details] [review] [SIGNED-OFF] Bug 16217: Resync names of notices Bug 12752 has fixed a bug for installations upgrading from 3.14, but has not fixed the problem for new installations. Because of some wrong data manipulations, the names for a given letter code may diverge. In particular OVERDUE and PREDUE names of phone notices have been wrongly modify by bug 11867: they have been set to the name of the first HOLD notice. Trying to be back on our feet, this update DB entry will try to guess and set back up the correct name. To know if your install is affected by this bug, the following SQL query can help you: SELECT code, name, message_transport_type FROM letter WHERE code="PREDUE" OR code="OVERDUE"; If the names are different for the same code, something went wrong. Executing this update DB entry should fix the divergence. Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> Fix the problem, see comment #6 for test. No koha-qa errors
(In reply to Jonathan Druart from comment #8) > Sorry, > my $dbh = C4::Context->dbh > was missing in the .perl file. NP, I never made an atomic .perl, did not know it was necessary. Regards
Jonathan: Shouldn't we repair some old db revs here too, if that is possible? If you didn't upgrade yet, can we do it right in the first run?
Hi Marcel, we are looking at the same bugs again - take a look at bug 12752 for the database update entry fix! Can you finish here?
(In reply to Katrin Fischer from comment #12) > Hi Marcel, we are looking at the same bugs again - take a look at bug 12752 > for the database update entry fix! Can you finish here? OK I will continue here now.
Created attachment 50877 [details] [review] Bug 16217: Resync names of notices Bug 12752 has fixed a bug for installations upgrading from 3.14, but has not fixed the problem for new installations. Because of some wrong data manipulations, the names for a given letter code may diverge. In particular OVERDUE and PREDUE names of phone notices have been wrongly modify by bug 11867: they have been set to the name of the first HOLD notice. Trying to be back on our feet, this update DB entry will try to guess and set back up the correct name. To know if your install is affected by this bug, the following SQL query can help you: SELECT code, name, message_transport_type FROM letter WHERE code="PREDUE" OR code="OVERDUE"; If the names are different for the same code, something went wrong. Executing this update DB entry should fix the divergence. Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> Fix the problem, see comment #6 for test. No koha-qa errors Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Passed QA Note that all notice names are considered, not only DUE/PREDUE.
Pushed to Master - Should be in the May 2016 Release. Thanks!
Patch pushed to 3.22.x, will be in 3.22.7