Bugzilla – Attachment 21551 Details for
Bug 10965
Sample itemtypes can't load on new install
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10965 - Sample itemtypes can't load on new install
Bug-10965---Sample-itemtypes-cant-load-on-new-inst.patch (text/plain), 2.27 KB, created by
Bernardo Gonzalez Kriegel
on 2013-09-28 19:46:32 UTC
(
hide
)
Description:
Bug 10965 - Sample itemtypes can't load on new install
Filename:
MIME Type:
Creator:
Bernardo Gonzalez Kriegel
Created:
2013-09-28 19:46:32 UTC
Size:
2.27 KB
patch
obsolete
>From effa8d230bd5c724e2959c9d56cfd620fafd2a58 Mon Sep 17 00:00:00 2001 >From: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> >Date: Sat, 28 Sep 2013 16:24:50 -0300 >Subject: [PATCH] Bug 10965 - Sample itemtypes can't load on new install > >Bug 10513 added two columns to table itemtypes, >but sample_itemtypes can't be loaded because >it relies on old structure. > >This patch rewrites sample_itemtypes.sql, stating >explicitly columns, removing backticks and consolidates >all in one insertion. > >To test: >1) On master with current DB structure, delete item types > >2) try loading sample_itemtyes.sql >It fails with "ERROR 1136 (21S01) at line 1: Column count doesn't match value count at row 1" > >3) apply patch > >4) try again, this time it will load and itemtypes created >--- > .../data/mysql/en/optional/sample_itemtypes.sql | 17 +++++++++-------- > 1 file changed, 9 insertions(+), 8 deletions(-) > >diff --git a/installer/data/mysql/en/optional/sample_itemtypes.sql b/installer/data/mysql/en/optional/sample_itemtypes.sql >index 76510b4..6c3a612 100644 >--- a/installer/data/mysql/en/optional/sample_itemtypes.sql >+++ b/installer/data/mysql/en/optional/sample_itemtypes.sql >@@ -1,8 +1,9 @@ >-INSERT INTO `itemtypes` VALUES ('BK', 'Books',5,0,'bridge/book.gif',''); >-INSERT INTO `itemtypes` VALUES ('MX', 'Mixed Materials',5,0,'bridge/kit.gif',''); >-INSERT INTO `itemtypes` VALUES ('CF', 'Computer Files',5,0,'bridge/computer_file.gif',''); >-INSERT INTO `itemtypes` VALUES ('MP', 'Maps',5,0,'bridge/map.gif',''); >-INSERT INTO `itemtypes` VALUES ('VM', 'Visual Materials',5,1,'bridge/dvd.gif',''); >-INSERT INTO `itemtypes` VALUES ('MU', 'Music',5,0,'bridge/sound.gif',''); >-INSERT INTO `itemtypes` VALUES ('CR', 'Continuing Resources',5,0,'bridge/periodical.gif',''); >-INSERT INTO `itemtypes` VALUES ('REF', 'Reference',0,1,'',''); >+INSERT INTO itemtypes (itemtype, description, rentalcharge, notforloan, imageurl, summary) VALUES >+('BK', 'Books',5,0,'bridge/book.gif',''), >+('MX', 'Mixed Materials',5,0,'bridge/kit.gif',''), >+('CF', 'Computer Files',5,0,'bridge/computer_file.gif',''), >+('MP', 'Maps',5,0,'bridge/map.gif',''), >+('VM', 'Visual Materials',5,1,'bridge/dvd.gif',''), >+('MU', 'Music',5,0,'bridge/sound.gif',''), >+('CR', 'Continuing Resources',5,0,'bridge/periodical.gif',''), >+('REF', 'Reference',0,1,'',''); >-- >1.7.9.5
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 10965
:
21551
|
21567
|
21597