Bug 7245 - Errors in MySQL tables population with mandatory data for italian installation
Summary: Errors in MySQL tables population with mandatory data for italian installation
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: I18N/L10N (show other bugs)
Version: 3.6
Hardware: PC Linux
: PATCH-Sent (DO NOT USE) normal (vote)
Assignee: Frédéric Demians
QA Contact: Ian Walls
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-18 15:19 UTC by Fabio Tiana
Modified: 2013-12-05 19:59 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
screenshot of errors in web installer (66.12 KB, image/png)
2011-11-18 15:19 UTC, Fabio Tiana
Details
correct sample_itemtypes.sql (671 bytes, patch)
2011-11-18 15:51 UTC, Fabio Tiana
Details | Diff | Splinter Review
correct unimarc_framework.sql (823.37 KB, patch)
2011-11-18 15:52 UTC, Fabio Tiana
Details | Diff | Splinter Review
Proposed patch (14.65 KB, patch)
2011-11-20 12:16 UTC, Frédéric Demians
Details | Diff | Splinter Review
sign-off of the patch (14.70 KB, patch)
2011-11-20 19:55 UTC, Zeno Tajoli
Details | Diff | Splinter Review
patch with fileds (as asked RM) (15.28 KB, patch)
2011-12-13 12:58 UTC, Zeno Tajoli
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Fabio Tiana 2011-11-18 15:19:24 UTC
Created attachment 6337 [details]
screenshot of errors in web installer

While installing italian and UNIMARC version of Koha via web installer, two errors occur: ERROR 1136 (21S01) and ERROR 1064 (42000). Some tables can't be populated with mandatory data.

Errors are related to files sample_itemtypes.sql and unimarc_framework.sql (/usr/share/koha/intranet/cgi-bin/installer/data/mysql/it-IT/ and subdirectories).
Comment 1 Fabio Tiana 2011-11-18 15:51:01 UTC Comment hidden (obsolete)
Comment 2 Fabio Tiana 2011-11-18 15:52:59 UTC Comment hidden (obsolete)
Comment 3 Frédéric Demians 2011-11-18 15:55:26 UTC
Thanks. Can you submit those corrected files as patches? Do you know how to do that?
Comment 4 Fabio Tiana 2011-11-18 16:02:21 UTC
You're welcome! Correct sql files are now attached, please check/test.

Errors were related to sample_itemtypes.sql and unimarc_framework.sql.

sample_itemtypes.sql INSERTs took one more field than expected by itemtypes table. I deleted the fifth value (originally set to 0 for each query), so now the fields are 6 insted of 7 (that is wrong).

As to unimarc_framework.sql, the first two INSERT were performed as expected. The errors in the comments' syntax started from row 18, preventing the tables from being populated.

Fabio
Comment 5 Frédéric Demians 2011-11-20 12:16:46 UTC Comment hidden (obsolete)
Comment 6 Zeno Tajoli 2011-11-20 15:49:19 UTC
Tested patch.
It is all.
I sign-off the patch
Comment 7 Zeno Tajoli 2011-11-20 19:55:12 UTC Comment hidden (obsolete)
Comment 8 Paul Poulain 2011-12-12 16:56:22 UTC
QA comment: I hesitate to mark failed QA but... there is a big mistake in the sql files: they are using short SQL statements:
+INSERT INTO `itemtypes` VALUES ('BK', 'Libro',5,0,'bridge/book.gif','');
and not

+INSERT INTO `itemtypes` (field1, field2, field3, field4, field5,...) VALUES ('BK', 'Libro',5,0,'bridge/book.gif','');

it means that the next modification in itemtypes will result in this bug being reopened, because it will fail again.

Could you please fix the SQL and add the field names ?

marking failed QA,
Comment 9 Frédéric Demians 2011-12-13 06:56:14 UTC
(In reply to comment #8)
> QA comment: I hesitate to mark failed QA but... there is a big mistake in the
> sql files: they are using short SQL statements:
> +INSERT INTO `itemtypes` VALUES ('BK', 'Libro',5,0,'bridge/book.gif','');
> and not
> 
> +INSERT INTO `itemtypes` (field1, field2, field3, field4, field5,...) VALUES
> ('BK', 'Libro',5,0,'bridge/book.gif','');
> 
> it means that the next modification in itemtypes will result in this bug being
> reopened, because it will fail again.
> 
> Could you please fix the SQL and add the field names ?
> 
> marking failed QA,

You're right. it-IT/necessari/sample_itemtypes.sql contains incorrect SQL statements. But those statements are not introduced but this patch. There are already there in HEAD. IMO this issue should be covered by a separated bugzilla entry, and the attached patch should be applied since it fixes a real and current issue.
Comment 10 Zeno Tajoli 2011-12-13 12:58:43 UTC
Created attachment 6744 [details] [review]
patch with fileds (as asked RM)

The patch with fields in sql insert
Comment 11 Paul Poulain 2011-12-13 13:44:16 UTC
QA comment: no comment now, small patch.

I've tested, it works fine. Patch pushed, please test.


PS : welcome Fabio, you're 165th !
Comment 12 Paul Poulain 2011-12-13 17:27:42 UTC
Just for the record:
(In reply to comment #9)
> You're right. it-IT/necessari/sample_itemtypes.sql contains incorrect SQL
> statements. But those statements are not introduced but this patch. There are
> already there in HEAD. IMO this issue should be covered by a separated bugzilla
> entry, and the attached patch should be applied since it fixes a real and
> current issue.

Frederic was right, and I would have pushed the incomplete patch today if the proper patch had not been submitted.
I'll write something on the wiki about how we (QA team) / I (RM) accept a patch or no.
Comment 13 Katrin Fischer 2012-04-12 20:41:19 UTC
Was changed by accident, setting back to original status.
Comment 14 Jared Camins-Esakov 2012-05-24 00:58:02 UTC
This patch was incorporated into the 3.6.x branch prior to 3.6.4.