3

My magento version is 2.2.2
I tried to upgrade my version into 2.2.5CE But it shows an error

SQLSTATE[42S02]: Base table or view not found: 1932 Table 'amsi_shopmgnto.catalogrule_product_replica' doesn't exist in engine, query was: SELECT COUNT(1) AS rows FROM catalogrule_product_replica

I checked it in my db the table entry is there but when I tried to retrieve the columns it showed an error

Error Code: 1932. Table 'catalogrule_product_replica' doesn't exist in engine

Any solution for this issue? My cron is not working I can't update my version also.

4
  • did you find any solution? Commented Sep 10, 2018 at 5:54
  • @Camit1dk I hav't got any solution for this, what i did is a simple hack, I re-created that table, by coping sql from my local server. It is working till now. I don't know what will be the end result. Still looking for a good solution. Commented Sep 10, 2018 at 6:05
  • @Camit1dk Could you give us the command to recreate the table please Commented Nov 15, 2018 at 18:17
  • @MerGh sorry i did not find solution and not able to recreated. Can you try to reindex its may be regenerate this table. Commented Nov 16, 2018 at 16:06

1 Answer 1

0

Try create/recreate table with this sql

DROP TABLE IF EXISTS `catalogrule_product_replica`;
CREATE TABLE `catalogrule_product_replica` (
  `rule_product_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Rule Product Id',
  `rule_id` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'Rule Id',
  `from_time` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'From Time',
  `to_time` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'To time',
  `customer_group_id` int(11) DEFAULT NULL,
  `product_id` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'Product Id',
  `action_operator` varchar(10) DEFAULT 'to_fixed' COMMENT 'Action Operator',
  `action_amount` decimal(12,4) NOT NULL DEFAULT '0.0000' COMMENT 'Action Amount',
  `action_stop` smallint(6) NOT NULL DEFAULT '0' COMMENT 'Action Stop',
  `sort_order` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'Sort Order',
  `website_id` smallint(5) unsigned NOT NULL COMMENT 'Website Id',
  PRIMARY KEY (`rule_product_id`),
  UNIQUE KEY `IDX_EAA51B56FF092A0DCB795D1CEF812B7B` (`rule_id`,`from_time`,`to_time`,`website_id`,`customer_group_id`,`product_id`,`sort_order`),
  KEY `CATALOGRULE_PRODUCT_CUSTOMER_GROUP_ID` (`customer_group_id`),
  KEY `CATALOGRULE_PRODUCT_WEBSITE_ID` (`website_id`),
  KEY `CATALOGRULE_PRODUCT_FROM_TIME` (`from_time`),
  KEY `CATALOGRULE_PRODUCT_TO_TIME` (`to_time`),
  KEY `CATALOGRULE_PRODUCT_PRODUCT_ID` (`product_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='CatalogRule Product';

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.