Jump to content

Manual upgraded from 1.5.2 to 1.5.4 shows failed queries in XML


Recommended Posts

Hello,

 

I have a dev version of my current shop wich i want to upgrade. The upgrade went succesful because i can login to backoffice etc page is showing,, some theme errors but that i have to fix.. but the outputed XML for the SQL queries showed some failed items. Now i wonder if this is good or not. Also I have to mention that i did 2 manual upgrades the first was in chrome but then power went off... so then i edited the config file again to 1.5.2 and run the manual update again showing this:

 

<?xml version="1.0" encoding="UTF-8"?><action result="fail" error="34">
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[sET NAMES 'utf8']]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.0">
   <sqlQuery><![CDATA[/* PHP:outstanding_allow_amount1530(); */]]></sqlQuery>
  </request>
<request result="ok" sqlfile="1.5.3.0">
   <sqlQuery><![CDATA[/* PHP:blocknewsletter1530(); */]]></sqlQuery>
  </request>
<request result="ok" sqlfile="1.5.3.0">
   <sqlQuery><![CDATA[/* PHP:block_category_1521(); */]]></sqlQuery>
  </request>
<request result="ok" sqlfile="1.5.3.0">
   <sqlQuery><![CDATA[/* PHP:update_order_messages(); */]]></sqlQuery>
  </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[uPDATE `ps_order_state` SET `delivery` = 0 WHERE `id_order_state` = 3]]></sqlQuery>
 </request>
<request result="fail" sqlfile="1.5.3.0" >
 <sqlQuery><![CDATA[ALTER TABLE  `ps_product_shop` ADD `id_product_redirected` int(10) unsigned NOT NULL default '0' AFTER `active`]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'id_product_redirected']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="fail" sqlfile="1.5.3.0" >
 <sqlQuery><![CDATA[ALTER TABLE  `ps_product` ADD `id_product_redirected` int(10) unsigned NOT NULL default '0' AFTER `active`]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'id_product_redirected']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[uPDATE `ps_order_state` SET `send_email` = 1 WHERE `id_order_state` = (SELECT `value` FROM `ps_configuration` WHERE `name` = 'PS_OS_WS_PAYMENT' LIMIT 1)]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[uPDATE `ps_order_state_lang` SET `template` = 'payment' WHERE `id_order_state` = (SELECT `value` FROM `ps_configuration` WHERE `name` = 'PS_OS_WS_PAYMENT' LIMIT 1)]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[DELETE FROM `ps_configuration` WHERE `name`= 'PS_HIGH_HTML_THEME_COMPRESSION']]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[iNSERT INTO `ps_configuration`(`name`, `value`, `date_add`, `date_upd`) VALUES ('PS_MAIL_COLOR', '#db3484', NOW(), NOW())]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[ALTER TABLE `ps_order_cart_rule` CHANGE `name` `name` VARCHAR(254)]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[ALTER TABLE `ps_cart` CHANGE `delivery_option` `delivery_option` TEXT CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL]]></sqlQuery>
 </request>
<request result="fail" sqlfile="1.5.3.0" >
 <sqlQuery><![CDATA[ALTER TABLE `ps_currency_shop` ADD `conversion_rate` DECIMAL( 13, 6 ) NOT NULL]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'conversion_rate']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[uPDATE `ps_currency_shop` a SET `conversion_rate` = (SELECT `conversion_rate` FROM `ps_currency` b WHERE a.id_currency = b.id_currency)]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[iNSERT INTO `ps_configuration`(`name`, `value`, `id_shop`, `id_shop_group`, `date_add`, `date_upd`)
(SELECT 'PS_GIFT_WRAPPING_TAX_RULES_GROUP', b.`id_tax_rules_group`, a.`id_shop`, a.`id_shop_group`, NOW(), NOW()
 FROM `ps_configuration` a
 JOIN `ps_tax_rule` b ON (a.value = b.id_tax)
 WHERE a.name='PS_GIFT_WRAPPING_TAX'
 GROUP BY a.`id_shop`, a.`id_shop_group`
)]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.0">
  <sqlQuery><![CDATA[DELETE FROM `ps_configuration` WHERE name='PS_GIFT_WRAPPING_TAX']]></sqlQuery>
 </request>
<request result="fail" sqlfile="1.5.3.0" >
 <sqlQuery><![CDATA[ALTER TABLE  `ps_cart_rule` ADD `highlight` tinyint(1) unsigned NOT NULL default 0 AFTER `gift_product_attribute`]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'highlight']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="ok" sqlfile="1.5.3.1">
  <sqlQuery><![CDATA[sET NAMES 'utf8']]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.3.1">
   <sqlQuery><![CDATA[/* PHP:p1531_redirect_type(); */]]></sqlQuery>
  </request>
<request result="ok" sqlfile="1.5.3.1">
  <sqlQuery><![CDATA[ALTER TABLE `ps_cart` CHANGE `delivery_option` `delivery_option` TEXT NOT NULL]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[sET NAMES 'utf8']]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
   <sqlQuery><![CDATA[/* PHP:update_customer_default_group(); */]]></sqlQuery>
  </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_meta` SET `page` = 'supplier' WHERE `page` = 'supply']]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[ALTER TABLE  `ps_image_type` CHANGE  `name`  `name` VARCHAR( 64 ) NOT NULL]]></sqlQuery>
 </request>
<request result="fail" sqlfile="1.5.4.0" >
 <sqlQuery><![CDATA[ALTER TABLE `ps_customer` ADD `id_lang` INT UNSIGNED NULL AFTER `id_default_group`]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'id_lang']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_customer` SET id_lang = (SELECT `value` FROM `ps_configuration` WHERE name = 'PS_LANG_DEFAULT' LIMIT 1)]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_customer` c, `ps_orders` o SET c.id_lang = o.id_lang WHERE c.id_customer = o.id_customer]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_quick_access` SET `link` = 'index.php?controller=AdminCartRules&addcart_rule' WHERE `link` = 'index.php?tab=AdminDiscounts&adddiscount']]></sqlQuery>
 </request>
<request result="fail" sqlfile="1.5.4.0" >
 <sqlQuery><![CDATA[ALTER TABLE `ps_order_cart_rule` ADD `free_shipping` tinyint(1) NOT NULL DEFAULT 0 AFTER `value_tax_excl`]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'free_shipping']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_order_cart_rule` ocr, `ps_cart_rule` cr SET ocr.free_shipping = 1 WHERE ocr.id_cart_rule = cr.id_cart_rule AND cr.free_shipping = 1]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_orders` o, `ps_order_cart_rule` ocr SET
o.`total_discounts` = o.total_discounts + o.`total_shipping_tax_incl`,
o.`total_discounts_tax_incl` = o.`total_discounts_tax_incl` + o.`total_shipping_tax_incl`,
o.`total_discounts_tax_excl` = o.`total_discounts_tax_excl` + o.`total_shipping_tax_excl`
WHERE o.id_order = ocr.id_order AND ocr.free_shipping = 1]]></sqlQuery>
 </request>
<request result="fail" sqlfile="1.5.4.0" >
 <sqlQuery><![CDATA[CREATE TABLE `ps_tab_module_preference` (
 `id_tab_module_preference` int(11) NOT NULL auto_increment,
 `id_employee` int(11) NOT NULL,
 `id_tab` int(11) NOT NULL,
 `module` varchar(255) NOT NULL,
 PRIMARY KEY (`id_tab_module_preference`),
 UNIQUE KEY `employee_module` (`id_employee`, `id_tab`, `module`)
) ENGINE=InnoDB  DEFAULT CHARSET=utf8]]></sqlQuery>
 <sqlMsgError><![CDATA[Table 'ps_tab_module_preference' already exists]]></sqlMsgError>
  <sqlNumberError><![CDATA[1050]]></sqlNumberError>
 </request>
<request result="ok" sqlfile="1.5.4.0">
   <sqlQuery><![CDATA[/* PHP:add_new_tab(AdminMarketing, es:Marketing|it:Marketing|en:Marketing|de:Marketing|fr:Marketing,  1); */]]></sqlQuery>
  </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[ALTER TABLE `ps_stock_available` DROP INDEX `product_sqlstock`]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[ALTER TABLE `ps_stock_available` ADD UNIQUE `product_sqlstock` (`id_product`, `id_product_attribute`, `id_shop`, `id_shop_group`)]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE ps_configuration SET `value` = '8388608' WHERE `name` = 'PS_PRODUCT_PICTURE_MAX_SIZE' AND `value` <= '524288']]></sqlQuery>
 </request>
<request result="fail" sqlfile="1.5.4.0" >
 <sqlQuery><![CDATA[ALTER TABLE `ps_guest` ADD `mobile_theme` tinyint(1) NOT NULL DEFAULT 0]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'mobile_theme']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="fail" sqlfile="1.5.4.0" >
 <sqlQuery><![CDATA[ALTER TABLE `ps_orders` ADD `mobile_theme` tinyint(1) NOT NULL DEFAULT 0 AFTER `gift_message`]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'mobile_theme']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="fail" sqlfile="1.5.4.0" >
 <sqlQuery><![CDATA[ALTER TABLE `ps_cart` ADD `mobile_theme` tinyint(1) NOT NULL DEFAULT 0 AFTER `gift_message`]]></sqlQuery>
 <sqlMsgError><![CDATA[Duplicate column name 'mobile_theme']]></sqlMsgError>
  <sqlNumberError><![CDATA[1060]]></sqlNumberError>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[ALTER TABLE `ps_address` CHANGE `phone` `phone` varchar(32) default NULL]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[ALTER TABLE `ps_address` CHANGE `phone_mobile` `phone_mobile` varchar(32) default NULL]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
   <sqlQuery><![CDATA[/* PHP:update_genders_images(); */]]></sqlQuery>
  </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_customer` SET `id_gender` = 1 WHERE `email` LIKE '[email protected]' AND `id_customer` = 1 AND `id_gender` = 4]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_cart_rule_carrier` crc INNER JOIN `ps_carrier` c ON crc.`id_carrier` = c.`id_carrier` SET crc.`id_carrier` = c.`id_reference`]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
  <sqlQuery><![CDATA[uPDATE `ps_order_payment` SET `order_reference` = LPAD(order_reference, 9 , '0')]]></sqlQuery>
 </request>
<request result="ok" sqlfile="1.5.4.0">
   <sqlQuery><![CDATA[/* PHP:p1540_add_missing_columns(); */]]></sqlQuery>
  </request>
</action>

 

as you can see many items are OK but some also failed.. is this a problem and how can i fix it? should i run the queries in PHPmyAdmin?

Link to comment
Share on other sites

you need to think about what happened, and then read the queries and it should become obvious.

 

you said you execute the upgrade and the power went off. that means that the upgrade executed and either finished completely, or if you are running the site on your localhost, then it finished partly.

 

You then say that some sql queries failed when you performed the upgrade a second time. Well, didn't those SQL queries already execute the first time? So when you run them a second time, you might expect them to fail? For instance, this query below is telling you that the column 'id_product_redirected' already exists... well I would expect it to exist since you executed the upgrade the first time

 

<request result="fail" sqlfile="1.5.3.0" >

<sqlQuery><![CDATA[ALTER TABLE `ps_product_shop` ADD `id_product_redirected` int(10) unsigned NOT NULL default '0' AFTER `active`]]></sqlQuery>

<sqlMsgError><![CDATA[Duplicate column name 'id_product_redirected']]></sqlMsgError>

 

Now what you should have done after the power went out, is to restore the database from a pre-upgrade backup, and then execute the upgrade again.

Link to comment
Share on other sites

  • 2 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...