INSERT INTO `url_rewrite` VALUES ('570168','product','429','consectetur-adipiscing.html','catalog/product/view/id/429',0,13,NULL,1,NULL),('570169','product','429','home-electronics/consectetur-adipiscing.html','catalog/product/view/id/429/category/339',0,13,NULL,1,'{\"category_id\":\"339\"}'),('570170','product','429','home-electronics/cell-phones/consectetur-adipiscing.html','catalog/product/view/id/429/category/356',0,13,NULL,1,'{\"category_id\":\"356\"}'),('570171','product','429','home-electronics/cell-phones/cellphone-accessories/consectetur-adipiscing.html','catalog/product/view/id/429/category/357',0,13,NULL,1,'{\"category_id\":\"357\"}'),('570172','product','429','home-electronics/cell-phones/mobile-hotspots-plans/consectetur-adipiscing.html','catalog/product/view/id/429/category/358',0,13,NULL,1,'{\"category_id\":\"358\"}'),('570173','product','429','home-electronics/cell-phones/phones-with-plans/consectetur-adipiscing.html','catalog/product/view/id/429/category/359',0,13,NULL,1,'{\"category_id\":\"359\"}'),('570174','product','429','home-electronics/cell-phones/prepaid-plans/consectetur-adipiscing.html','catalog/product/view/id/429/category/360',0,13,NULL,1,'{\"category_id\":\"360\"}'),('570175','product','429','home-electronics/gps-navigation/consectetur-adipiscing.html','catalog/product/view/id/429/category/369',0,13,NULL,1,'{\"category_id\":\"369\"}'),('570176','product','429','home-electronics/gps-navigation/accessories/consectetur-adipiscing.html','catalog/product/view/id/429/category/370',0,13,NULL,1,'{\"category_id\":\"370\"}'),('570177','product','429','home-electronics/home-audio-theater/consectetur-adipiscing.html','catalog/product/view/id/429/category/378',0,13,NULL,1,'{\"category_id\":\"378\"}'),('570178','product','429','home-electronics/home-audio-theater/home-theater/consectetur-adipiscing.html','catalog/product/view/id/429/category/379',0,13,NULL,1,'{\"category_id\":\"379\"}'),('570179','product','429','home-electronics/home-audio-theater/sports/consectetur-adipiscing.html','catalog/product/view/id/429/category/380',0,13,NULL,1,'{\"category_id\":\"380\"}'),('570180','product','429','home-electronics/home-audio-theater/stereo-receivers/consectetur-adipiscing.html','catalog/product/view/id/429/category/381',0,13,NULL,1,'{\"category_id\":\"381\"}'),('570181','product','429','home-electronics/home-audio-theater/surround-sound-speakers/consectetur-adipiscing.html','catalog/product/view/id/429/category/382',0,13,NULL,1,'{\"category_id\":\"382\"}'),('570182','product','429','home-electronics/gps-navigation/auto-gps-units/consectetur-adipiscing.html','catalog/product/view/id/429/category/392',0,13,NULL,1,'{\"category_id\":\"392\"}'),('570183','product','429','home-electronics/gps-navigation/fitness-gps-units/consectetur-adipiscing.html','catalog/product/view/id/429/category/393',0,13,NULL,1,'{\"category_id\":\"393\"}'),('570184','product','429','home-electronics/gps-navigation/handheld-gps-units/consectetur-adipiscing.html','catalog/product/view/id/429/category/394',0,13,NULL,1,'{\"category_id\":\"394\"}'),('570185','product','429','home-electronics/home-audio-theater/surround-sound-speakers-systems/consectetur-adipiscing.html','home-electronics/home-audio-theater/surround-sound-speakers/consectetur-adipiscing.html',301,13,NULL,0,'{\"category_id\":\"382\"}'),('570186','product','429','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/consectetur-adipiscing.html','home-electronics/home-audio-theater/stereo-receivers/consectetur-adipiscing.html',301,13,NULL,0,'{\"category_id\":\"381\"}'),('570187','product','430','donec-bibendum-diam.html','catalog/product/view/id/430',0,13,NULL,1,NULL),('570188','product','430','home-electronics/donec-bibendum-diam.html','catalog/product/view/id/430/category/339',0,13,NULL,1,'{\"category_id\":\"339\"}'),('570189','product','430','home-electronics/cell-phones/donec-bibendum-diam.html','catalog/product/view/id/430/category/356',0,13,NULL,1,'{\"category_id\":\"356\"}'),('570190','product','430','home-electronics/cell-phones/cellphone-accessories/donec-bibendum-diam.html','catalog/product/view/id/430/category/357',0,13,NULL,1,'{\"category_id\":\"357\"}'),('570191','product','430','home-electronics/cell-phones/mobile-hotspots-plans/donec-bibendum-diam.html','catalog/product/view/id/430/category/358',0,13,NULL,1,'{\"category_id\":\"358\"}'),('570192','product','430','home-electronics/cell-phones/phones-with-plans/donec-bibendum-diam.html','catalog/product/view/id/430/category/359',0,13,NULL,1,'{\"category_id\":\"359\"}'),('570193','product','430','home-electronics/cell-phones/prepaid-plans/donec-bibendum-diam.html','catalog/product/view/id/430/category/360',0,13,NULL,1,'{\"category_id\":\"360\"}'),('570194','product','430','home-electronics/gps-navigation/donec-bibendum-diam.html','catalog/product/view/id/430/category/369',0,13,NULL,1,'{\"category_id\":\"369\"}'),('570195','product','430','home-electronics/gps-navigation/accessories/donec-bibendum-diam.html','catalog/product/view/id/430/category/370',0,13,NULL,1,'{\"category_id\":\"370\"}'),('570196','product','430','home-electronics/home-audio-theater/donec-bibendum-diam.html','catalog/product/view/id/430/category/378',0,13,NULL,1,'{\"category_id\":\"378\"}'),('570197','product','430','home-electronics/home-audio-theater/home-theater/donec-bibendum-diam.html','catalog/product/view/id/430/category/379',0,13,NULL,1,'{\"category_id\":\"379\"}'),('570198','product','430','home-electronics/home-audio-theater/sports/donec-bibendum-diam.html','catalog/product/view/id/430/category/380',0,13,NULL,1,'{\"category_id\":\"380\"}'),('570199','product','430','home-electronics/home-audio-theater/stereo-receivers/donec-bibendum-diam.html','catalog/product/view/id/430/category/381',0,13,NULL,1,'{\"category_id\":\"381\"}'),('570200','product','430','home-electronics/home-audio-theater/surround-sound-speakers/donec-bibendum-diam.html','catalog/product/view/id/430/category/382',0,13,NULL,1,'{\"category_id\":\"382\"}'),('570201','product','430','home-electronics/gps-navigation/auto-gps-units/donec-bibendum-diam.html','catalog/product/view/id/430/category/392',0,13,NULL,1,'{\"category_id\":\"392\"}'),('570202','product','430','home-electronics/gps-navigation/fitness-gps-units/donec-bibendum-diam.html','catalog/product/view/id/430/category/393',0,13,NULL,1,'{\"category_id\":\"393\"}'),('570203','product','430','home-electronics/gps-navigation/handheld-gps-units/donec-bibendum-diam.html','catalog/product/view/id/430/category/394',0,13,NULL,1,'{\"category_id\":\"394\"}'),('570204','product','430','home-electronics/home-audio-theater/surround-sound-speakers-systems/donec-bibendum-diam.html','home-electronics/home-audio-theater/surround-sound-speakers/donec-bibendum-diam.html',301,13,NULL,0,'{\"category_id\":\"382\"}'),('570205','product','430','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/donec-bibendum-diam.html','home-electronics/home-audio-theater/stereo-receivers/donec-bibendum-diam.html',301,13,NULL,0,'{\"category_id\":\"381\"}'),('570206','product','431','etiam-fringilla-posuere.html','catalog/product/view/id/431',0,13,NULL,1,NULL),('570207','product','431','home-electronics/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/339',0,13,NULL,1,'{\"category_id\":\"339\"}'),('570208','product','431','home-electronics/cell-phones/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/356',0,13,NULL,1,'{\"category_id\":\"356\"}'),('570209','product','431','home-electronics/cell-phones/cellphone-accessories/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/357',0,13,NULL,1,'{\"category_id\":\"357\"}'),('570210','product','431','home-electronics/cell-phones/mobile-hotspots-plans/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/358',0,13,NULL,1,'{\"category_id\":\"358\"}'),('570211','product','431','home-electronics/cell-phones/phones-with-plans/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/359',0,13,NULL,1,'{\"category_id\":\"359\"}'),('570212','product','431','home-electronics/cell-phones/prepaid-plans/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/360',0,13,NULL,1,'{\"category_id\":\"360\"}'),('570213','product','431','home-electronics/gps-navigation/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/369',0,13,NULL,1,'{\"category_id\":\"369\"}'),('570214','product','431','home-electronics/gps-navigation/accessories/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/370',0,13,NULL,1,'{\"category_id\":\"370\"}'),('570215','product','431','home-electronics/home-audio-theater/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/378',0,13,NULL,1,'{\"category_id\":\"378\"}'),('570216','product','431','home-electronics/home-audio-theater/home-theater/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/379',0,13,NULL,1,'{\"category_id\":\"379\"}'),('570217','product','431','home-electronics/home-audio-theater/sports/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/380',0,13,NULL,1,'{\"category_id\":\"380\"}'),('570218','product','431','home-electronics/home-audio-theater/stereo-receivers/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/381',0,13,NULL,1,'{\"category_id\":\"381\"}'),('570219','product','431','home-electronics/home-audio-theater/surround-sound-speakers/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/382',0,13,NULL,1,'{\"category_id\":\"382\"}'),('570220','product','431','home-electronics/gps-navigation/auto-gps-units/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/392',0,13,NULL,1,'{\"category_id\":\"392\"}'),('570221','product','431','home-electronics/gps-navigation/fitness-gps-units/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/393',0,13,NULL,1,'{\"category_id\":\"393\"}'),('570222','product','431','home-electronics/gps-navigation/handheld-gps-units/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/394',0,13,NULL,1,'{\"category_id\":\"394\"}'),('570223','product','431','home-electronics/home-audio-theater/surround-sound-speakers-systems/etiam-fringilla-posuere.html','home-electronics/home-audio-theater/surround-sound-speakers/etiam-fringilla-posuere.html',301,13,NULL,0,'{\"category_id\":\"382\"}'),('570224','product','431','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/etiam-fringilla-posuere.html','home-electronics/home-audio-theater/stereo-receivers/etiam-fringilla-posuere.html',301,13,NULL,0,'{\"category_id\":\"381\"}'),('570225','product','449','leo-sollicitudin-nec.html','catalog/product/view/id/449',0,13,NULL,1,NULL),('570226','product','449','home-electronics/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/339',0,13,NULL,1,'{\"category_id\":\"339\"}'),('570227','product','449','home-electronics/cell-phones/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/356',0,13,NULL,1,'{\"category_id\":\"356\"}'),('570228','product','449','home-electronics/cell-phones/cellphone-accessories/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/357',0,13,NULL,1,'{\"category_id\":\"357\"}'),('570229','product','449','home-electronics/cell-phones/mobile-hotspots-plans/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/358',0,13,NULL,1,'{\"category_id\":\"358\"}'),('570230','product','449','home-electronics/cell-phones/phones-with-plans/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/359',0,13,NULL,1,'{\"category_id\":\"359\"}'),('570231','product','449','home-electronics/cell-phones/prepaid-plans/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/360',0,13,NULL,1,'{\"category_id\":\"360\"}'),('570232','product','449','home-electronics/gps-navigation/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/369',0,13,NULL,1,'{\"category_id\":\"369\"}'),('570233','product','449','home-electronics/gps-navigation/accessories/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/370',0,13,NULL,1,'{\"category_id\":\"370\"}'),('570234','product','449','home-electronics/home-audio-theater/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/378',0,13,NULL,1,'{\"category_id\":\"378\"}'),('570235','product','449','home-electronics/home-audio-theater/home-theater/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/379',0,13,NULL,1,'{\"category_id\":\"379\"}'),('570236','product','449','home-electronics/home-audio-theater/sports/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/380',0,13,NULL,1,'{\"category_id\":\"380\"}'),('570237','product','449','home-electronics/home-audio-theater/stereo-receivers/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/381',0,13,NULL,1,'{\"category_id\":\"381\"}'),('570238','product','449','home-electronics/home-audio-theater/surround-sound-speakers/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/382',0,13,NULL,1,'{\"category_id\":\"382\"}'),('570239','product','449','home-electronics/gps-navigation/auto-gps-units/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/392',0,13,NULL,1,'{\"category_id\":\"392\"}'),('570240','product','449','home-electronics/gps-navigation/fitness-gps-units/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/393',0,13,NULL,1,'{\"category_id\":\"393\"}'),('570241','product','449','home-electronics/gps-navigation/handheld-gps-units/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/394',0,13,NULL,1,'{\"category_id\":\"394\"}'),('570242','product','449','home-electronics/home-audio-theater/surround-sound-speakers-systems/leo-sollicitudin-nec.html','home-electronics/home-audio-theater/surround-sound-speakers/leo-sollicitudin-nec.html',301,13,NULL,0,'{\"category_id\":\"382\"}'),('570243','product','449','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/leo-sollicitudin-nec.html','home-electronics/home-audio-theater/stereo-receivers/leo-sollicitudin-nec.html',301,13,NULL,0,'{\"category_id\":\"381\"}'),('570244','product','379','smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379',0,15,NULL,1,NULL),('570245','product','379','home-electronics/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570246','product','379','home-electronics/cell-phones/cellphone-accessories/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570247','product','379','home-electronics/cell-phones/mobile-hotspots-plans/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570248','product','379','home-electronics/cell-phones/phones-with-plans/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570249','product','379','home-electronics/cell-phones/prepaid-plans/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570250','product','379','home-electronics/home-audio-theater/home-theater/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570251','product','379','home-electronics/home-audio-theater/sports/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570252','product','379','home-electronics/home-audio-theater/stereo-receivers/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570253','product','379','home-electronics/home-audio-theater/surround-sound-speakers/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570254','product','379','home-electronics/cell-phones/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570255','product','379','home-electronics/gps-navigation/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570256','product','379','home-electronics/home-audio-theater/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570257','product','379','home-electronics/gps-navigation/accessories/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570258','product','379','home-electronics/gps-navigation/auto-gps-units/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570259','product','379','home-electronics/gps-navigation/fitness-gps-units/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570260','product','379','home-electronics/gps-navigation/handheld-gps-units/smartwatch-2-0-lte-wifi.html','catalog/product/view/id/379/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570261','product','379','home-electronics/home-audio-theater/surround-sound-speakers-systems/smartwatch-2-0-lte-wifi.html','home-electronics/home-audio-theater/surround-sound-speakers/smartwatch-2-0-lte-wifi.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570262','product','379','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/smartwatch-2-0-lte-wifi.html','home-electronics/home-audio-theater/stereo-receivers/smartwatch-2-0-lte-wifi.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570263','product','380','smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380',0,15,NULL,1,NULL),('570264','product','380','home-electronics/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570265','product','380','home-electronics/cell-phones/cellphone-accessories/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570266','product','380','home-electronics/cell-phones/mobile-hotspots-plans/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570267','product','380','home-electronics/cell-phones/phones-with-plans/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570268','product','380','home-electronics/cell-phones/prepaid-plans/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570269','product','380','home-electronics/home-audio-theater/home-theater/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570270','product','380','home-electronics/home-audio-theater/sports/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570271','product','380','home-electronics/home-audio-theater/stereo-receivers/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570272','product','380','home-electronics/home-audio-theater/surround-sound-speakers/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570273','product','380','home-electronics/cell-phones/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570274','product','380','home-electronics/gps-navigation/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570275','product','380','home-electronics/home-audio-theater/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570276','product','380','home-electronics/gps-navigation/accessories/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570277','product','380','home-electronics/gps-navigation/auto-gps-units/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570278','product','380','home-electronics/gps-navigation/fitness-gps-units/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570279','product','380','home-electronics/gps-navigation/handheld-gps-units/smartwatch-2-0-lte-wifi-1.html','catalog/product/view/id/380/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570280','product','380','home-electronics/home-audio-theater/surround-sound-speakers-systems/smartwatch-2-0-lte-wifi-1.html','home-electronics/home-audio-theater/surround-sound-speakers/smartwatch-2-0-lte-wifi-1.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570281','product','380','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/smartwatch-2-0-lte-wifi-1.html','home-electronics/home-audio-theater/stereo-receivers/smartwatch-2-0-lte-wifi-1.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570282','product','416','apple-cinema-30.html','catalog/product/view/id/416',0,15,NULL,1,NULL),('570283','product','416','home-electronics/apple-cinema-30.html','catalog/product/view/id/416/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570284','product','416','home-electronics/cell-phones/apple-cinema-30.html','catalog/product/view/id/416/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570285','product','416','home-electronics/cell-phones/cellphone-accessories/apple-cinema-30.html','catalog/product/view/id/416/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570286','product','416','home-electronics/cell-phones/mobile-hotspots-plans/apple-cinema-30.html','catalog/product/view/id/416/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570287','product','416','home-electronics/cell-phones/phones-with-plans/apple-cinema-30.html','catalog/product/view/id/416/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570288','product','416','home-electronics/cell-phones/prepaid-plans/apple-cinema-30.html','catalog/product/view/id/416/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570289','product','416','home-electronics/gps-navigation/apple-cinema-30.html','catalog/product/view/id/416/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570290','product','416','home-electronics/gps-navigation/accessories/apple-cinema-30.html','catalog/product/view/id/416/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570291','product','416','home-electronics/home-audio-theater/apple-cinema-30.html','catalog/product/view/id/416/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570292','product','416','home-electronics/home-audio-theater/home-theater/apple-cinema-30.html','catalog/product/view/id/416/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570293','product','416','home-electronics/home-audio-theater/sports/apple-cinema-30.html','catalog/product/view/id/416/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570294','product','416','home-electronics/home-audio-theater/stereo-receivers/apple-cinema-30.html','catalog/product/view/id/416/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570295','product','416','home-electronics/home-audio-theater/surround-sound-speakers/apple-cinema-30.html','catalog/product/view/id/416/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570296','product','416','home-electronics/gps-navigation/auto-gps-units/apple-cinema-30.html','catalog/product/view/id/416/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570297','product','416','home-electronics/gps-navigation/fitness-gps-units/apple-cinema-30.html','catalog/product/view/id/416/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570298','product','416','home-electronics/gps-navigation/handheld-gps-units/apple-cinema-30.html','catalog/product/view/id/416/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570299','product','416','home-electronics/home-audio-theater/surround-sound-speakers-systems/apple-cinema-30.html','home-electronics/home-audio-theater/surround-sound-speakers/apple-cinema-30.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570300','product','416','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/apple-cinema-30.html','home-electronics/home-audio-theater/stereo-receivers/apple-cinema-30.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570301','product','417','apple-ipod-classic.html','catalog/product/view/id/417',0,15,NULL,1,NULL),('570302','product','417','home-electronics/apple-ipod-classic.html','catalog/product/view/id/417/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570303','product','417','home-electronics/cell-phones/apple-ipod-classic.html','catalog/product/view/id/417/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570304','product','417','home-electronics/cell-phones/cellphone-accessories/apple-ipod-classic.html','catalog/product/view/id/417/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570305','product','417','home-electronics/cell-phones/mobile-hotspots-plans/apple-ipod-classic.html','catalog/product/view/id/417/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570306','product','417','home-electronics/cell-phones/phones-with-plans/apple-ipod-classic.html','catalog/product/view/id/417/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570307','product','417','home-electronics/cell-phones/prepaid-plans/apple-ipod-classic.html','catalog/product/view/id/417/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570308','product','417','home-electronics/gps-navigation/apple-ipod-classic.html','catalog/product/view/id/417/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570309','product','417','home-electronics/gps-navigation/accessories/apple-ipod-classic.html','catalog/product/view/id/417/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570310','product','417','home-electronics/home-audio-theater/apple-ipod-classic.html','catalog/product/view/id/417/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570311','product','417','home-electronics/home-audio-theater/home-theater/apple-ipod-classic.html','catalog/product/view/id/417/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570312','product','417','home-electronics/home-audio-theater/sports/apple-ipod-classic.html','catalog/product/view/id/417/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570313','product','417','home-electronics/home-audio-theater/stereo-receivers/apple-ipod-classic.html','catalog/product/view/id/417/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570314','product','417','home-electronics/home-audio-theater/surround-sound-speakers/apple-ipod-classic.html','catalog/product/view/id/417/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570315','product','417','home-electronics/gps-navigation/auto-gps-units/apple-ipod-classic.html','catalog/product/view/id/417/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570316','product','417','home-electronics/gps-navigation/fitness-gps-units/apple-ipod-classic.html','catalog/product/view/id/417/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570317','product','417','home-electronics/gps-navigation/handheld-gps-units/apple-ipod-classic.html','catalog/product/view/id/417/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570318','product','417','home-electronics/home-audio-theater/surround-sound-speakers-systems/apple-ipod-classic.html','home-electronics/home-audio-theater/surround-sound-speakers/apple-ipod-classic.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570319','product','417','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/apple-ipod-classic.html','home-electronics/home-audio-theater/stereo-receivers/apple-ipod-classic.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570320','product','418','apple-ipod-nano.html','catalog/product/view/id/418',0,15,NULL,1,NULL),('570321','product','418','home-electronics/apple-ipod-nano.html','catalog/product/view/id/418/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570322','product','418','home-electronics/cell-phones/apple-ipod-nano.html','catalog/product/view/id/418/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570323','product','418','home-electronics/cell-phones/cellphone-accessories/apple-ipod-nano.html','catalog/product/view/id/418/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570324','product','418','home-electronics/cell-phones/mobile-hotspots-plans/apple-ipod-nano.html','catalog/product/view/id/418/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570325','product','418','home-electronics/cell-phones/phones-with-plans/apple-ipod-nano.html','catalog/product/view/id/418/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570326','product','418','home-electronics/cell-phones/prepaid-plans/apple-ipod-nano.html','catalog/product/view/id/418/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570327','product','418','home-electronics/gps-navigation/apple-ipod-nano.html','catalog/product/view/id/418/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570328','product','418','home-electronics/gps-navigation/accessories/apple-ipod-nano.html','catalog/product/view/id/418/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570329','product','418','home-electronics/home-audio-theater/apple-ipod-nano.html','catalog/product/view/id/418/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570330','product','418','home-electronics/home-audio-theater/home-theater/apple-ipod-nano.html','catalog/product/view/id/418/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570331','product','418','home-electronics/home-audio-theater/sports/apple-ipod-nano.html','catalog/product/view/id/418/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570332','product','418','home-electronics/home-audio-theater/stereo-receivers/apple-ipod-nano.html','catalog/product/view/id/418/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570333','product','418','home-electronics/home-audio-theater/surround-sound-speakers/apple-ipod-nano.html','catalog/product/view/id/418/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570334','product','418','home-electronics/gps-navigation/auto-gps-units/apple-ipod-nano.html','catalog/product/view/id/418/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570335','product','418','home-electronics/gps-navigation/fitness-gps-units/apple-ipod-nano.html','catalog/product/view/id/418/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570336','product','418','home-electronics/gps-navigation/handheld-gps-units/apple-ipod-nano.html','catalog/product/view/id/418/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570337','product','418','home-electronics/home-audio-theater/surround-sound-speakers-systems/apple-ipod-nano.html','home-electronics/home-audio-theater/surround-sound-speakers/apple-ipod-nano.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570338','product','418','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/apple-ipod-nano.html','home-electronics/home-audio-theater/stereo-receivers/apple-ipod-nano.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570339','product','419','apple-ipod-shuffle.html','catalog/product/view/id/419',0,15,NULL,1,NULL),('570340','product','419','home-electronics/apple-ipod-shuffle.html','catalog/product/view/id/419/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570341','product','419','home-electronics/cell-phones/apple-ipod-shuffle.html','catalog/product/view/id/419/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570342','product','419','home-electronics/cell-phones/cellphone-accessories/apple-ipod-shuffle.html','catalog/product/view/id/419/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570343','product','419','home-electronics/cell-phones/mobile-hotspots-plans/apple-ipod-shuffle.html','catalog/product/view/id/419/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570344','product','419','home-electronics/cell-phones/phones-with-plans/apple-ipod-shuffle.html','catalog/product/view/id/419/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570345','product','419','home-electronics/cell-phones/prepaid-plans/apple-ipod-shuffle.html','catalog/product/view/id/419/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570346','product','419','home-electronics/gps-navigation/apple-ipod-shuffle.html','catalog/product/view/id/419/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570347','product','419','home-electronics/gps-navigation/accessories/apple-ipod-shuffle.html','catalog/product/view/id/419/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570348','product','419','home-electronics/home-audio-theater/apple-ipod-shuffle.html','catalog/product/view/id/419/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570349','product','419','home-electronics/home-audio-theater/home-theater/apple-ipod-shuffle.html','catalog/product/view/id/419/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570350','product','419','home-electronics/home-audio-theater/sports/apple-ipod-shuffle.html','catalog/product/view/id/419/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570351','product','419','home-electronics/home-audio-theater/stereo-receivers/apple-ipod-shuffle.html','catalog/product/view/id/419/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570352','product','419','home-electronics/home-audio-theater/surround-sound-speakers/apple-ipod-shuffle.html','catalog/product/view/id/419/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570353','product','419','home-electronics/gps-navigation/auto-gps-units/apple-ipod-shuffle.html','catalog/product/view/id/419/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570354','product','419','home-electronics/gps-navigation/fitness-gps-units/apple-ipod-shuffle.html','catalog/product/view/id/419/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570355','product','419','home-electronics/gps-navigation/handheld-gps-units/apple-ipod-shuffle.html','catalog/product/view/id/419/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570356','product','419','home-electronics/home-audio-theater/surround-sound-speakers-systems/apple-ipod-shuffle.html','home-electronics/home-audio-theater/surround-sound-speakers/apple-ipod-shuffle.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570357','product','419','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/apple-ipod-shuffle.html','home-electronics/home-audio-theater/stereo-receivers/apple-ipod-shuffle.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570358','product','420','apple-ipod-touch.html','catalog/product/view/id/420',0,15,NULL,1,NULL),('570359','product','420','home-electronics/apple-ipod-touch.html','catalog/product/view/id/420/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570360','product','420','home-electronics/cell-phones/apple-ipod-touch.html','catalog/product/view/id/420/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570361','product','420','home-electronics/cell-phones/cellphone-accessories/apple-ipod-touch.html','catalog/product/view/id/420/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570362','product','420','home-electronics/cell-phones/mobile-hotspots-plans/apple-ipod-touch.html','catalog/product/view/id/420/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570363','product','420','home-electronics/cell-phones/phones-with-plans/apple-ipod-touch.html','catalog/product/view/id/420/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570364','product','420','home-electronics/cell-phones/prepaid-plans/apple-ipod-touch.html','catalog/product/view/id/420/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570365','product','420','home-electronics/gps-navigation/apple-ipod-touch.html','catalog/product/view/id/420/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570366','product','420','home-electronics/gps-navigation/accessories/apple-ipod-touch.html','catalog/product/view/id/420/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570367','product','420','home-electronics/home-audio-theater/apple-ipod-touch.html','catalog/product/view/id/420/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570368','product','420','home-electronics/home-audio-theater/home-theater/apple-ipod-touch.html','catalog/product/view/id/420/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570369','product','420','home-electronics/home-audio-theater/sports/apple-ipod-touch.html','catalog/product/view/id/420/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570370','product','420','home-electronics/home-audio-theater/stereo-receivers/apple-ipod-touch.html','catalog/product/view/id/420/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570371','product','420','home-electronics/home-audio-theater/surround-sound-speakers/apple-ipod-touch.html','catalog/product/view/id/420/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570372','product','420','home-electronics/gps-navigation/auto-gps-units/apple-ipod-touch.html','catalog/product/view/id/420/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570373','product','420','home-electronics/gps-navigation/fitness-gps-units/apple-ipod-touch.html','catalog/product/view/id/420/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570374','product','420','home-electronics/gps-navigation/handheld-gps-units/apple-ipod-touch.html','catalog/product/view/id/420/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570375','product','420','home-electronics/home-audio-theater/surround-sound-speakers-systems/apple-ipod-touch.html','home-electronics/home-audio-theater/surround-sound-speakers/apple-ipod-touch.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570376','product','420','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/apple-ipod-touch.html','home-electronics/home-audio-theater/stereo-receivers/apple-ipod-touch.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570377','product','421','blandit-pellentesque.html','catalog/product/view/id/421',0,15,NULL,1,NULL),('570378','product','421','home-electronics/blandit-pellentesque.html','catalog/product/view/id/421/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570379','product','421','home-electronics/cell-phones/blandit-pellentesque.html','catalog/product/view/id/421/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570380','product','421','home-electronics/cell-phones/cellphone-accessories/blandit-pellentesque.html','catalog/product/view/id/421/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570381','product','421','home-electronics/cell-phones/mobile-hotspots-plans/blandit-pellentesque.html','catalog/product/view/id/421/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570382','product','421','home-electronics/cell-phones/phones-with-plans/blandit-pellentesque.html','catalog/product/view/id/421/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570383','product','421','home-electronics/cell-phones/prepaid-plans/blandit-pellentesque.html','catalog/product/view/id/421/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570384','product','421','home-electronics/gps-navigation/blandit-pellentesque.html','catalog/product/view/id/421/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570385','product','421','home-electronics/gps-navigation/accessories/blandit-pellentesque.html','catalog/product/view/id/421/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570386','product','421','home-electronics/home-audio-theater/blandit-pellentesque.html','catalog/product/view/id/421/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570387','product','421','home-electronics/home-audio-theater/home-theater/blandit-pellentesque.html','catalog/product/view/id/421/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570388','product','421','home-electronics/home-audio-theater/sports/blandit-pellentesque.html','catalog/product/view/id/421/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570389','product','421','home-electronics/home-audio-theater/stereo-receivers/blandit-pellentesque.html','catalog/product/view/id/421/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570390','product','421','home-electronics/home-audio-theater/surround-sound-speakers/blandit-pellentesque.html','catalog/product/view/id/421/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570391','product','421','home-electronics/gps-navigation/auto-gps-units/blandit-pellentesque.html','catalog/product/view/id/421/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570392','product','421','home-electronics/gps-navigation/fitness-gps-units/blandit-pellentesque.html','catalog/product/view/id/421/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570393','product','421','home-electronics/gps-navigation/handheld-gps-units/blandit-pellentesque.html','catalog/product/view/id/421/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570394','product','421','home-electronics/home-audio-theater/surround-sound-speakers-systems/blandit-pellentesque.html','home-electronics/home-audio-theater/surround-sound-speakers/blandit-pellentesque.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570395','product','421','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/blandit-pellentesque.html','home-electronics/home-audio-theater/stereo-receivers/blandit-pellentesque.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570396','product','423','alexgt-smart-watches.html','catalog/product/view/id/423',0,15,NULL,1,NULL),('570397','product','423','home-electronics/alexgt-smart-watches.html','catalog/product/view/id/423/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570398','product','423','home-electronics/cell-phones/alexgt-smart-watches.html','catalog/product/view/id/423/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570399','product','423','home-electronics/cell-phones/cellphone-accessories/alexgt-smart-watches.html','catalog/product/view/id/423/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570400','product','423','home-electronics/cell-phones/mobile-hotspots-plans/alexgt-smart-watches.html','catalog/product/view/id/423/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570401','product','423','home-electronics/cell-phones/phones-with-plans/alexgt-smart-watches.html','catalog/product/view/id/423/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570402','product','423','home-electronics/cell-phones/prepaid-plans/alexgt-smart-watches.html','catalog/product/view/id/423/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570403','product','423','home-electronics/gps-navigation/alexgt-smart-watches.html','catalog/product/view/id/423/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570404','product','423','home-electronics/gps-navigation/accessories/alexgt-smart-watches.html','catalog/product/view/id/423/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570405','product','423','home-electronics/home-audio-theater/alexgt-smart-watches.html','catalog/product/view/id/423/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570406','product','423','home-electronics/home-audio-theater/home-theater/alexgt-smart-watches.html','catalog/product/view/id/423/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570407','product','423','home-electronics/home-audio-theater/sports/alexgt-smart-watches.html','catalog/product/view/id/423/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570408','product','423','home-electronics/home-audio-theater/stereo-receivers/alexgt-smart-watches.html','catalog/product/view/id/423/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570409','product','423','home-electronics/home-audio-theater/surround-sound-speakers/alexgt-smart-watches.html','catalog/product/view/id/423/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570410','product','423','home-electronics/gps-navigation/auto-gps-units/alexgt-smart-watches.html','catalog/product/view/id/423/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570411','product','423','home-electronics/gps-navigation/fitness-gps-units/alexgt-smart-watches.html','catalog/product/view/id/423/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570412','product','423','home-electronics/gps-navigation/handheld-gps-units/alexgt-smart-watches.html','catalog/product/view/id/423/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570413','product','423','home-electronics/home-audio-theater/surround-sound-speakers-systems/alexgt-smart-watches.html','home-electronics/home-audio-theater/surround-sound-speakers/alexgt-smart-watches.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570414','product','423','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/alexgt-smart-watches.html','home-electronics/home-audio-theater/stereo-receivers/alexgt-smart-watches.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570415','product','425','smart-watch.html','catalog/product/view/id/425',0,15,NULL,1,NULL),('570416','product','425','home-electronics/smart-watch.html','catalog/product/view/id/425/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570417','product','425','home-electronics/cell-phones/smart-watch.html','catalog/product/view/id/425/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570418','product','425','home-electronics/cell-phones/cellphone-accessories/smart-watch.html','catalog/product/view/id/425/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570419','product','425','home-electronics/cell-phones/mobile-hotspots-plans/smart-watch.html','catalog/product/view/id/425/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570420','product','425','home-electronics/cell-phones/phones-with-plans/smart-watch.html','catalog/product/view/id/425/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570421','product','425','home-electronics/cell-phones/prepaid-plans/smart-watch.html','catalog/product/view/id/425/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570422','product','425','home-electronics/gps-navigation/smart-watch.html','catalog/product/view/id/425/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570423','product','425','home-electronics/gps-navigation/accessories/smart-watch.html','catalog/product/view/id/425/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570424','product','425','home-electronics/home-audio-theater/smart-watch.html','catalog/product/view/id/425/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570425','product','425','home-electronics/home-audio-theater/home-theater/smart-watch.html','catalog/product/view/id/425/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570426','product','425','home-electronics/home-audio-theater/sports/smart-watch.html','catalog/product/view/id/425/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570427','product','425','home-electronics/home-audio-theater/stereo-receivers/smart-watch.html','catalog/product/view/id/425/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570428','product','425','home-electronics/home-audio-theater/surround-sound-speakers/smart-watch.html','catalog/product/view/id/425/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570429','product','425','home-electronics/gps-navigation/auto-gps-units/smart-watch.html','catalog/product/view/id/425/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570430','product','425','home-electronics/gps-navigation/fitness-gps-units/smart-watch.html','catalog/product/view/id/425/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570431','product','425','home-electronics/gps-navigation/handheld-gps-units/smart-watch.html','catalog/product/view/id/425/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570432','product','425','home-electronics/home-audio-theater/surround-sound-speakers-systems/smart-watch.html','home-electronics/home-audio-theater/surround-sound-speakers/smart-watch.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570433','product','425','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/smart-watch.html','home-electronics/home-audio-theater/stereo-receivers/smart-watch.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570434','product','427','pinnacle-foods-birds-1.html','catalog/product/view/id/427',0,15,NULL,1,NULL),('570435','product','427','home-electronics/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570436','product','427','home-electronics/cell-phones/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570437','product','427','home-electronics/cell-phones/cellphone-accessories/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570438','product','427','home-electronics/cell-phones/mobile-hotspots-plans/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570439','product','427','home-electronics/cell-phones/phones-with-plans/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570440','product','427','home-electronics/cell-phones/prepaid-plans/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570441','product','427','home-electronics/gps-navigation/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570442','product','427','home-electronics/gps-navigation/accessories/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570443','product','427','home-electronics/home-audio-theater/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570444','product','427','home-electronics/home-audio-theater/home-theater/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570445','product','427','home-electronics/home-audio-theater/sports/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570446','product','427','home-electronics/home-audio-theater/stereo-receivers/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570447','product','427','home-electronics/home-audio-theater/surround-sound-speakers/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570448','product','427','home-electronics/gps-navigation/auto-gps-units/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570449','product','427','home-electronics/gps-navigation/fitness-gps-units/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570450','product','427','home-electronics/gps-navigation/handheld-gps-units/pinnacle-foods-birds-1.html','catalog/product/view/id/427/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570451','product','427','home-electronics/home-audio-theater/surround-sound-speakers-systems/pinnacle-foods-birds-1.html','home-electronics/home-audio-theater/surround-sound-speakers/pinnacle-foods-birds-1.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570452','product','427','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/pinnacle-foods-birds-1.html','home-electronics/home-audio-theater/stereo-receivers/pinnacle-foods-birds-1.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570453','product','428','congue-ut-ligula.html','catalog/product/view/id/428',0,15,NULL,1,NULL),('570454','product','428','home-electronics/congue-ut-ligula.html','catalog/product/view/id/428/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570455','product','428','home-electronics/cell-phones/congue-ut-ligula.html','catalog/product/view/id/428/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570456','product','428','home-electronics/cell-phones/cellphone-accessories/congue-ut-ligula.html','catalog/product/view/id/428/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570457','product','428','home-electronics/cell-phones/mobile-hotspots-plans/congue-ut-ligula.html','catalog/product/view/id/428/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570458','product','428','home-electronics/cell-phones/phones-with-plans/congue-ut-ligula.html','catalog/product/view/id/428/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570459','product','428','home-electronics/cell-phones/prepaid-plans/congue-ut-ligula.html','catalog/product/view/id/428/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570460','product','428','home-electronics/gps-navigation/congue-ut-ligula.html','catalog/product/view/id/428/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570461','product','428','home-electronics/gps-navigation/accessories/congue-ut-ligula.html','catalog/product/view/id/428/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570462','product','428','home-electronics/home-audio-theater/congue-ut-ligula.html','catalog/product/view/id/428/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570463','product','428','home-electronics/home-audio-theater/home-theater/congue-ut-ligula.html','catalog/product/view/id/428/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570464','product','428','home-electronics/home-audio-theater/sports/congue-ut-ligula.html','catalog/product/view/id/428/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570465','product','428','home-electronics/home-audio-theater/stereo-receivers/congue-ut-ligula.html','catalog/product/view/id/428/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570466','product','428','home-electronics/home-audio-theater/surround-sound-speakers/congue-ut-ligula.html','catalog/product/view/id/428/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570467','product','428','home-electronics/gps-navigation/auto-gps-units/congue-ut-ligula.html','catalog/product/view/id/428/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570468','product','428','home-electronics/gps-navigation/fitness-gps-units/congue-ut-ligula.html','catalog/product/view/id/428/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570469','product','428','home-electronics/gps-navigation/handheld-gps-units/congue-ut-ligula.html','catalog/product/view/id/428/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570470','product','428','home-electronics/home-audio-theater/surround-sound-speakers-systems/congue-ut-ligula.html','home-electronics/home-audio-theater/surround-sound-speakers/congue-ut-ligula.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570471','product','428','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/congue-ut-ligula.html','home-electronics/home-audio-theater/stereo-receivers/congue-ut-ligula.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570472','product','429','consectetur-adipiscing.html','catalog/product/view/id/429',0,15,NULL,1,NULL),('570473','product','429','home-electronics/consectetur-adipiscing.html','catalog/product/view/id/429/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570474','product','429','home-electronics/cell-phones/consectetur-adipiscing.html','catalog/product/view/id/429/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570475','product','429','home-electronics/cell-phones/cellphone-accessories/consectetur-adipiscing.html','catalog/product/view/id/429/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570476','product','429','home-electronics/cell-phones/mobile-hotspots-plans/consectetur-adipiscing.html','catalog/product/view/id/429/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570477','product','429','home-electronics/cell-phones/phones-with-plans/consectetur-adipiscing.html','catalog/product/view/id/429/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570478','product','429','home-electronics/cell-phones/prepaid-plans/consectetur-adipiscing.html','catalog/product/view/id/429/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570479','product','429','home-electronics/gps-navigation/consectetur-adipiscing.html','catalog/product/view/id/429/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570480','product','429','home-electronics/gps-navigation/accessories/consectetur-adipiscing.html','catalog/product/view/id/429/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570481','product','429','home-electronics/home-audio-theater/consectetur-adipiscing.html','catalog/product/view/id/429/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570482','product','429','home-electronics/home-audio-theater/home-theater/consectetur-adipiscing.html','catalog/product/view/id/429/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570483','product','429','home-electronics/home-audio-theater/sports/consectetur-adipiscing.html','catalog/product/view/id/429/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570484','product','429','home-electronics/home-audio-theater/stereo-receivers/consectetur-adipiscing.html','catalog/product/view/id/429/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570485','product','429','home-electronics/home-audio-theater/surround-sound-speakers/consectetur-adipiscing.html','catalog/product/view/id/429/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570486','product','429','home-electronics/gps-navigation/auto-gps-units/consectetur-adipiscing.html','catalog/product/view/id/429/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570487','product','429','home-electronics/gps-navigation/fitness-gps-units/consectetur-adipiscing.html','catalog/product/view/id/429/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570488','product','429','home-electronics/gps-navigation/handheld-gps-units/consectetur-adipiscing.html','catalog/product/view/id/429/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570489','product','429','home-electronics/home-audio-theater/surround-sound-speakers-systems/consectetur-adipiscing.html','home-electronics/home-audio-theater/surround-sound-speakers/consectetur-adipiscing.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570490','product','429','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/consectetur-adipiscing.html','home-electronics/home-audio-theater/stereo-receivers/consectetur-adipiscing.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570491','product','430','donec-bibendum-diam.html','catalog/product/view/id/430',0,15,NULL,1,NULL),('570492','product','430','home-electronics/donec-bibendum-diam.html','catalog/product/view/id/430/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570493','product','430','home-electronics/cell-phones/donec-bibendum-diam.html','catalog/product/view/id/430/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570494','product','430','home-electronics/cell-phones/cellphone-accessories/donec-bibendum-diam.html','catalog/product/view/id/430/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570495','product','430','home-electronics/cell-phones/mobile-hotspots-plans/donec-bibendum-diam.html','catalog/product/view/id/430/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570496','product','430','home-electronics/cell-phones/phones-with-plans/donec-bibendum-diam.html','catalog/product/view/id/430/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570497','product','430','home-electronics/cell-phones/prepaid-plans/donec-bibendum-diam.html','catalog/product/view/id/430/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570498','product','430','home-electronics/gps-navigation/donec-bibendum-diam.html','catalog/product/view/id/430/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570499','product','430','home-electronics/gps-navigation/accessories/donec-bibendum-diam.html','catalog/product/view/id/430/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570500','product','430','home-electronics/home-audio-theater/donec-bibendum-diam.html','catalog/product/view/id/430/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570501','product','430','home-electronics/home-audio-theater/home-theater/donec-bibendum-diam.html','catalog/product/view/id/430/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570502','product','430','home-electronics/home-audio-theater/sports/donec-bibendum-diam.html','catalog/product/view/id/430/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570503','product','430','home-electronics/home-audio-theater/stereo-receivers/donec-bibendum-diam.html','catalog/product/view/id/430/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570504','product','430','home-electronics/home-audio-theater/surround-sound-speakers/donec-bibendum-diam.html','catalog/product/view/id/430/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570505','product','430','home-electronics/gps-navigation/auto-gps-units/donec-bibendum-diam.html','catalog/product/view/id/430/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570506','product','430','home-electronics/gps-navigation/fitness-gps-units/donec-bibendum-diam.html','catalog/product/view/id/430/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570507','product','430','home-electronics/gps-navigation/handheld-gps-units/donec-bibendum-diam.html','catalog/product/view/id/430/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570508','product','430','home-electronics/home-audio-theater/surround-sound-speakers-systems/donec-bibendum-diam.html','home-electronics/home-audio-theater/surround-sound-speakers/donec-bibendum-diam.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570509','product','430','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/donec-bibendum-diam.html','home-electronics/home-audio-theater/stereo-receivers/donec-bibendum-diam.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570510','product','431','etiam-fringilla-posuere.html','catalog/product/view/id/431',0,15,NULL,1,NULL),('570511','product','431','home-electronics/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570512','product','431','home-electronics/cell-phones/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570513','product','431','home-electronics/cell-phones/cellphone-accessories/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570514','product','431','home-electronics/cell-phones/mobile-hotspots-plans/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570515','product','431','home-electronics/cell-phones/phones-with-plans/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570516','product','431','home-electronics/cell-phones/prepaid-plans/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570517','product','431','home-electronics/gps-navigation/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570518','product','431','home-electronics/gps-navigation/accessories/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570519','product','431','home-electronics/home-audio-theater/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570520','product','431','home-electronics/home-audio-theater/home-theater/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570521','product','431','home-electronics/home-audio-theater/sports/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570522','product','431','home-electronics/home-audio-theater/stereo-receivers/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570523','product','431','home-electronics/home-audio-theater/surround-sound-speakers/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570524','product','431','home-electronics/gps-navigation/auto-gps-units/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570525','product','431','home-electronics/gps-navigation/fitness-gps-units/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570526','product','431','home-electronics/gps-navigation/handheld-gps-units/etiam-fringilla-posuere.html','catalog/product/view/id/431/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570527','product','431','home-electronics/home-audio-theater/surround-sound-speakers-systems/etiam-fringilla-posuere.html','home-electronics/home-audio-theater/surround-sound-speakers/etiam-fringilla-posuere.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570528','product','431','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/etiam-fringilla-posuere.html','home-electronics/home-audio-theater/stereo-receivers/etiam-fringilla-posuere.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570529','product','449','leo-sollicitudin-nec.html','catalog/product/view/id/449',0,15,NULL,1,NULL),('570530','product','449','home-electronics/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/339',0,15,NULL,1,'{\"category_id\":\"339\"}'),('570531','product','449','home-electronics/cell-phones/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/356',0,15,NULL,1,'{\"category_id\":\"356\"}'),('570532','product','449','home-electronics/cell-phones/cellphone-accessories/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/357',0,15,NULL,1,'{\"category_id\":\"357\"}'),('570533','product','449','home-electronics/cell-phones/mobile-hotspots-plans/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/358',0,15,NULL,1,'{\"category_id\":\"358\"}'),('570534','product','449','home-electronics/cell-phones/phones-with-plans/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/359',0,15,NULL,1,'{\"category_id\":\"359\"}'),('570535','product','449','home-electronics/cell-phones/prepaid-plans/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/360',0,15,NULL,1,'{\"category_id\":\"360\"}'),('570536','product','449','home-electronics/gps-navigation/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/369',0,15,NULL,1,'{\"category_id\":\"369\"}'),('570537','product','449','home-electronics/gps-navigation/accessories/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/370',0,15,NULL,1,'{\"category_id\":\"370\"}'),('570538','product','449','home-electronics/home-audio-theater/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/378',0,15,NULL,1,'{\"category_id\":\"378\"}'),('570539','product','449','home-electronics/home-audio-theater/home-theater/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/379',0,15,NULL,1,'{\"category_id\":\"379\"}'),('570540','product','449','home-electronics/home-audio-theater/sports/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/380',0,15,NULL,1,'{\"category_id\":\"380\"}'),('570541','product','449','home-electronics/home-audio-theater/stereo-receivers/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/381',0,15,NULL,1,'{\"category_id\":\"381\"}'),('570542','product','449','home-electronics/home-audio-theater/surround-sound-speakers/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/382',0,15,NULL,1,'{\"category_id\":\"382\"}'),('570543','product','449','home-electronics/gps-navigation/auto-gps-units/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/392',0,15,NULL,1,'{\"category_id\":\"392\"}'),('570544','product','449','home-electronics/gps-navigation/fitness-gps-units/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/393',0,15,NULL,1,'{\"category_id\":\"393\"}'),('570545','product','449','home-electronics/gps-navigation/handheld-gps-units/leo-sollicitudin-nec.html','catalog/product/view/id/449/category/394',0,15,NULL,1,'{\"category_id\":\"394\"}'),('570546','product','449','home-electronics/home-audio-theater/surround-sound-speakers-systems/leo-sollicitudin-nec.html','home-electronics/home-audio-theater/surround-sound-speakers/leo-sollicitudin-nec.html',301,15,NULL,0,'{\"category_id\":\"382\"}'),('570547','product','449','home-electronics/home-audio-theater/stereo-receivers-and-amplifiers/leo-sollicitudin-nec.html','home-electronics/home-audio-theater/stereo-receivers/leo-sollicitudin-nec.html',301,15,NULL,0,'{\"category_id\":\"381\"}'),('570548','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,2,NULL,1,NULL),('570549','product','526','shop/bigger-thicket-beard.html','catalog/product/view/id/526/category/256',0,2,NULL,1,'{\"category_id\":\"256\"}'),('570550','product','526','accessories/bigger-thicket-beard.html','catalog/product/view/id/526/category/281',0,2,NULL,1,'{\"category_id\":\"281\"}'),('570551','product','526','specials/bigger-thicket-beard.html','catalog/product/view/id/526/category/292',0,2,NULL,1,'{\"category_id\":\"292\"}'),('570552','product','526','living-room/bigger-thicket-beard.html','catalog/product/view/id/526/category/293',0,2,NULL,1,'{\"category_id\":\"293\"}'),('570553','product','526','bathroom/bigger-thicket-beard.html','catalog/product/view/id/526/category/320',0,2,NULL,1,'{\"category_id\":\"320\"}'),('570554','product','526','lightings/bigger-thicket-beard.html','catalog/product/view/id/526/category/331',0,2,NULL,1,'{\"category_id\":\"331\"}'),('570555','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,20,NULL,1,NULL),('570556','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,4,NULL,1,NULL),('570557','product','526','shop/bigger-thicket-beard.html','catalog/product/view/id/526/category/256',0,4,NULL,1,'{\"category_id\":\"256\"}'),('570558','product','526','accessories/bigger-thicket-beard.html','catalog/product/view/id/526/category/281',0,4,NULL,1,'{\"category_id\":\"281\"}'),('570559','product','526','specials/bigger-thicket-beard.html','catalog/product/view/id/526/category/292',0,4,NULL,1,'{\"category_id\":\"292\"}'),('570560','product','526','living-room/bigger-thicket-beard.html','catalog/product/view/id/526/category/293',0,4,NULL,1,'{\"category_id\":\"293\"}'),('570561','product','526','bathroom/bigger-thicket-beard.html','catalog/product/view/id/526/category/320',0,4,NULL,1,'{\"category_id\":\"320\"}'),('570562','product','526','lightings/bigger-thicket-beard.html','catalog/product/view/id/526/category/331',0,4,NULL,1,'{\"category_id\":\"331\"}'),('570563','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,6,NULL,1,NULL),('570564','product','526','shop/bigger-thicket-beard.html','catalog/product/view/id/526/category/256',0,6,NULL,1,'{\"category_id\":\"256\"}'),('570565','product','526','accessories/bigger-thicket-beard.html','catalog/product/view/id/526/category/281',0,6,NULL,1,'{\"category_id\":\"281\"}'),('570566','product','526','specials/bigger-thicket-beard.html','catalog/product/view/id/526/category/292',0,6,NULL,1,'{\"category_id\":\"292\"}'),('570567','product','526','living-room/bigger-thicket-beard.html','catalog/product/view/id/526/category/293',0,6,NULL,1,'{\"category_id\":\"293\"}'),('570568','product','526','bathroom/bigger-thicket-beard.html','catalog/product/view/id/526/category/320',0,6,NULL,1,'{\"category_id\":\"320\"}'),('570569','product','526','lightings/bigger-thicket-beard.html','catalog/product/view/id/526/category/331',0,6,NULL,1,'{\"category_id\":\"331\"}'),('570570','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,8,NULL,1,NULL),('570571','product','526','shop/bigger-thicket-beard.html','catalog/product/view/id/526/category/256',0,8,NULL,1,'{\"category_id\":\"256\"}'),('570572','product','526','accessories/bigger-thicket-beard.html','catalog/product/view/id/526/category/281',0,8,NULL,1,'{\"category_id\":\"281\"}'),('570573','product','526','specials/bigger-thicket-beard.html','catalog/product/view/id/526/category/292',0,8,NULL,1,'{\"category_id\":\"292\"}'),('570574','product','526','living-room/bigger-thicket-beard.html','catalog/product/view/id/526/category/293',0,8,NULL,1,'{\"category_id\":\"293\"}'),('570575','product','526','bathroom/bigger-thicket-beard.html','catalog/product/view/id/526/category/320',0,8,NULL,1,'{\"category_id\":\"320\"}'),('570576','product','526','lightings/bigger-thicket-beard.html','catalog/product/view/id/526/category/331',0,8,NULL,1,'{\"category_id\":\"331\"}'),('570577','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,10,NULL,1,NULL),('570578','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,12,NULL,1,NULL),('570579','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,14,NULL,1,NULL),('570580','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,16,NULL,1,NULL),('570581','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,18,NULL,1,NULL),('570582','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,1,NULL,1,NULL),('570583','product','526','shop/bigger-thicket-beard.html','catalog/product/view/id/526/category/256',0,1,NULL,1,'{\"category_id\":\"256\"}'),('570584','product','526','accessories/bigger-thicket-beard.html','catalog/product/view/id/526/category/281',0,1,NULL,1,'{\"category_id\":\"281\"}'),('570585','product','526','specials/bigger-thicket-beard.html','catalog/product/view/id/526/category/292',0,1,NULL,1,'{\"category_id\":\"292\"}'),('570586','product','526','living-room/bigger-thicket-beard.html','catalog/product/view/id/526/category/293',0,1,NULL,1,'{\"category_id\":\"293\"}'),('570587','product','526','bathroom/bigger-thicket-beard.html','catalog/product/view/id/526/category/320',0,1,NULL,1,'{\"category_id\":\"320\"}'),('570588','product','526','lightings/bigger-thicket-beard.html','catalog/product/view/id/526/category/331',0,1,NULL,1,'{\"category_id\":\"331\"}'),('570589','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,19,NULL,1,NULL),('570590','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,3,NULL,1,NULL),('570591','product','526','shop/bigger-thicket-beard.html','catalog/product/view/id/526/category/256',0,3,NULL,1,'{\"category_id\":\"256\"}'),('570592','product','526','accessories/bigger-thicket-beard.html','catalog/product/view/id/526/category/281',0,3,NULL,1,'{\"category_id\":\"281\"}'),('570593','product','526','specials/bigger-thicket-beard.html','catalog/product/view/id/526/category/292',0,3,NULL,1,'{\"category_id\":\"292\"}'),('570594','product','526','living-room/bigger-thicket-beard.html','catalog/product/view/id/526/category/293',0,3,NULL,1,'{\"category_id\":\"293\"}'),('570595','product','526','bathroom/bigger-thicket-beard.html','catalog/product/view/id/526/category/320',0,3,NULL,1,'{\"category_id\":\"320\"}'),('570596','product','526','lightings/bigger-thicket-beard.html','catalog/product/view/id/526/category/331',0,3,NULL,1,'{\"category_id\":\"331\"}'),('570597','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,5,NULL,1,NULL),('570598','product','526','shop/bigger-thicket-beard.html','catalog/product/view/id/526/category/256',0,5,NULL,1,'{\"category_id\":\"256\"}'),('570599','product','526','accessories/bigger-thicket-beard.html','catalog/product/view/id/526/category/281',0,5,NULL,1,'{\"category_id\":\"281\"}'),('570600','product','526','specials/bigger-thicket-beard.html','catalog/product/view/id/526/category/292',0,5,NULL,1,'{\"category_id\":\"292\"}'),('570601','product','526','living-room/bigger-thicket-beard.html','catalog/product/view/id/526/category/293',0,5,NULL,1,'{\"category_id\":\"293\"}'),('570602','product','526','bathroom/bigger-thicket-beard.html','catalog/product/view/id/526/category/320',0,5,NULL,1,'{\"category_id\":\"320\"}'),('570603','product','526','lightings/bigger-thicket-beard.html','catalog/product/view/id/526/category/331',0,5,NULL,1,'{\"category_id\":\"331\"}'),('570604','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,7,NULL,1,NULL),('570605','product','526','shop/bigger-thicket-beard.html','catalog/product/view/id/526/category/256',0,7,NULL,1,'{\"category_id\":\"256\"}'),('570606','product','526','accessories/bigger-thicket-beard.html','catalog/product/view/id/526/category/281',0,7,NULL,1,'{\"category_id\":\"281\"}'),('570607','product','526','specials/bigger-thicket-beard.html','catalog/product/view/id/526/category/292',0,7,NULL,1,'{\"category_id\":\"292\"}'),('570608','product','526','living-room/bigger-thicket-beard.html','catalog/product/view/id/526/category/293',0,7,NULL,1,'{\"category_id\":\"293\"}'),('570609','product','526','bathroom/bigger-thicket-beard.html','catalog/product/view/id/526/category/320',0,7,NULL,1,'{\"category_id\":\"320\"}'),('570610','product','526','lightings/bigger-thicket-beard.html','catalog/product/view/id/526/category/331',0,7,NULL,1,'{\"category_id\":\"331\"}'),('570611','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,9,NULL,1,NULL),('570612','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,11,NULL,1,NULL),('570613','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,13,NULL,1,NULL),('570614','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,15,NULL,1,NULL),('570615','product','526','bigger-thicket-beard.html','catalog/product/view/id/526',0,17,NULL,1,NULL);

--
-- Table structure for table `variable`
--

CREATE TABLE `variable` (
  `variable_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Variable ID',
  `code` varchar(255) DEFAULT NULL COMMENT 'Variable Code',
  `name` varchar(255) DEFAULT NULL COMMENT 'Variable Name',
  PRIMARY KEY (`variable_id`),
  UNIQUE KEY `VARIABLE_CODE` (`code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Variables';

--
-- Table structure for table `variable_value`
--

CREATE TABLE `variable_value` (
  `value_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Variable Value ID',
  `variable_id` int(10) unsigned NOT NULL DEFAULT 0 COMMENT 'Variable ID',
  `store_id` smallint(5) unsigned NOT NULL DEFAULT 0 COMMENT 'Store ID',
  `plain_value` text DEFAULT NULL COMMENT 'Plain Text Value',
  `html_value` text DEFAULT NULL COMMENT 'Html Value',
  PRIMARY KEY (`value_id`),
  UNIQUE KEY `VARIABLE_VALUE_VARIABLE_ID_STORE_ID` (`variable_id`,`store_id`),
  KEY `VARIABLE_VALUE_STORE_ID` (`store_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Variable Value';

--
-- Table structure for table `vault_payment_token`
--

CREATE TABLE `vault_payment_token` (
  `entity_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Entity ID',
  `customer_id` int(10) unsigned DEFAULT NULL COMMENT 'Customer ID',
  `public_hash` varchar(128) NOT NULL COMMENT 'Hash code for using on frontend',
  `payment_method_code` varchar(128) NOT NULL COMMENT 'Payment method code',
  `type` varchar(128) NOT NULL COMMENT 'Type',
  `created_at` timestamp NOT NULL DEFAULT current_timestamp() COMMENT 'Created At',
  `expires_at` timestamp NULL DEFAULT NULL COMMENT 'Expires At',
  `gateway_token` varchar(255) NOT NULL COMMENT 'Gateway Token',
  `details` text DEFAULT NULL COMMENT 'Details',
  `is_active` tinyint(1) NOT NULL DEFAULT 1,
  `is_visible` tinyint(1) NOT NULL DEFAULT 1,
  PRIMARY KEY (`entity_id`),
  UNIQUE KEY `VAULT_PAYMENT_TOKEN_PUBLIC_HASH` (`public_hash`),
  UNIQUE KEY `VAULT_PAYMENT_TOKEN_PAYMENT_METHOD_CODE_CSTR_ID_GATEWAY_TOKEN` (`payment_method_code`,`customer_id`,`gateway_token`),
  KEY `VAULT_PAYMENT_TOKEN_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` (`customer_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Vault tokens of payment';

--
-- Table structure for table `vault_payment_token_order_payment_link`
--

CREATE TABLE `vault_payment_token_order_payment_link` (
  `order_payment_id` int(10) unsigned NOT NULL COMMENT 'Order payment ID',
  `payment_token_id` int(10) unsigned NOT NULL COMMENT 'Payment token ID',
  PRIMARY KEY (`order_payment_id`,`payment_token_id`),
  KEY `FK_4ED894655446D385894580BECA993862` (`payment_token_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Order payments to vault token';

--
-- Table structure for table `vertex_commodity_code_order_item`
--

CREATE TABLE `vertex_commodity_code_order_item` (
  `order_item_id` int(10) unsigned NOT NULL COMMENT 'Item ID',
  `code` varchar(255) DEFAULT NULL COMMENT 'Commodity Code',
  `type` varchar(255) DEFAULT NULL COMMENT 'Commodity Type',
  PRIMARY KEY (`order_item_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Vertex Commodity Code';

--
-- Table structure for table `vertex_commodity_code_product`
--

CREATE TABLE `vertex_commodity_code_product` (
  `product_id` int(10) unsigned NOT NULL COMMENT 'Product ID',
  `code` varchar(255) DEFAULT NULL COMMENT 'Commodity Code',
  `type` varchar(255) DEFAULT NULL COMMENT 'Commodity Type',
  PRIMARY KEY (`product_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Vertex Commodity Code';

--
-- Table structure for table `vertex_custom_option_flex_field`
--

CREATE TABLE `vertex_custom_option_flex_field` (
  `entity_id` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Map Entity ID',
  `option_id` int(11) NOT NULL COMMENT 'Customizable Option ID',
  `website_id` int(11) NOT NULL DEFAULT 0 COMMENT 'Website ID',
  `flex_field` int(11) DEFAULT 0 COMMENT 'Customizable Option to Flex Field Map',
  PRIMARY KEY (`entity_id`),
  UNIQUE KEY `VERTEX_CUSTOM_OPTION_FLEX_FIELD_OPTION_ID_WEBSITE_ID` (`option_id`,`website_id`),
  KEY `VERTEX_CUSTOM_OPTION_FLEX_FIELD_OPTION_ID` (`option_id`),
  KEY `VERTEX_CUSTOM_OPTION_FLEX_FIELD_WEBSITE_ID` (`website_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Customizable Option to Flex Field Map';

--
-- Table structure for table `vertex_customer_code`
--

CREATE TABLE `vertex_customer_code` (
  `customer_id` int(10) unsigned NOT NULL COMMENT 'Customer ID',
  `customer_code` text DEFAULT NULL COMMENT 'Customer Code for Vertex',
  PRIMARY KEY (`customer_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Customer Code for Vertex';

--
-- Table structure for table `vertex_customer_country`
--

CREATE TABLE `vertex_customer_country` (
  `customer_id` int(10) unsigned NOT NULL COMMENT 'Customer ID',
  `customer_country` varchar(255) DEFAULT NULL COMMENT 'Customer Country',
  PRIMARY KEY (`customer_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Country associated to Customer';

--
-- Table structure for table `vertex_invoice_sent`
--

CREATE TABLE `vertex_invoice_sent` (
  `invoice_id` int(10) unsigned NOT NULL COMMENT 'Invoice ID',
  `sent_to_vertex` tinyint(1) NOT NULL DEFAULT 0 COMMENT 'Invoice has been logged in Vertex',
  PRIMARY KEY (`invoice_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

--
-- Table structure for table `vertex_order_invoice_status`
--

CREATE TABLE `vertex_order_invoice_status` (
  `order_id` int(10) unsigned NOT NULL COMMENT 'Order ID',
  `sent_to_vertex` tinyint(1) NOT NULL DEFAULT 0 COMMENT 'Invoice has been logged in Vertex',
  PRIMARY KEY (`order_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Invoice has been logged in Vertex';

--
-- Table structure for table `vertex_sales_creditmemo_item_invoice_text_code`
--

CREATE TABLE `vertex_sales_creditmemo_item_invoice_text_code` (
  `item_id` int(11) NOT NULL COMMENT 'Creditmemo Item ID',
  `invoice_text_code` varchar(100) NOT NULL COMMENT 'Invoice text code from Vertex',
  UNIQUE KEY `UNQ_4BC40DA748D7713ADA661D2DE1BCF161` (`item_id`,`invoice_text_code`),
  KEY `VERTEX_SALES_CREDITMEMO_ITEM_INVOICE_TEXT_CODE_ITEM_ID` (`item_id`),
  KEY `VERTEX_SALES_CREDITMEMO_ITEM_INVOICE_TEXT_CODE_INVOICE_TEXT_CODE` (`invoice_text_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Creditmemo text code from Vertex';

--
-- Table structure for table `vertex_sales_creditmemo_item_tax_code`
--

CREATE TABLE `vertex_sales_creditmemo_item_tax_code` (
  `item_id` int(11) NOT NULL COMMENT 'Creditmemo Item ID',
  `tax_code` varchar(100) NOT NULL COMMENT 'Invoice text code from Vertex',
  UNIQUE KEY `VERTEX_SALES_CREDITMEMO_ITEM_TAX_CODE_ITEM_ID_TAX_CODE` (`item_id`,`tax_code`),
  KEY `VERTEX_SALES_CREDITMEMO_ITEM_TAX_CODE_ITEM_ID` (`item_id`),
  KEY `VERTEX_SALES_CREDITMEMO_ITEM_TAX_CODE_TAX_CODE` (`tax_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Creditmemo tax code from Vertex';

--
-- Table structure for table `vertex_sales_creditmemo_item_vertex_tax_code`
--

CREATE TABLE `vertex_sales_creditmemo_item_vertex_tax_code` (
  `item_id` int(11) NOT NULL COMMENT 'Creditmemo Item ID',
  `vertex_tax_code` varchar(100) NOT NULL COMMENT 'Invoice text code from Vertex',
  UNIQUE KEY `UNQ_31D7AADB3412BC7E7C1C98D5CC3A5D46` (`item_id`,`vertex_tax_code`),
  KEY `VERTEX_SALES_CREDITMEMO_ITEM_VERTEX_TAX_CODE_ITEM_ID` (`item_id`),
  KEY `VERTEX_SALES_CREDITMEMO_ITEM_VERTEX_TAX_CODE_VERTEX_TAX_CODE` (`vertex_tax_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Creditmemo vertex tax code from Vertex';

--
-- Table structure for table `vertex_sales_order_item_invoice_text_code`
--

CREATE TABLE `vertex_sales_order_item_invoice_text_code` (
  `item_id` int(10) unsigned NOT NULL COMMENT 'Order ID',
  `invoice_text_code` varchar(100) NOT NULL COMMENT 'Invoice text code from Vertex',
  UNIQUE KEY `UNQ_96F6BE3160A4185CEA4D866018EAF6DC` (`item_id`,`invoice_text_code`),
  KEY `VERTEX_SALES_ORDER_ITEM_INVOICE_TEXT_CODE_ITEM_ID` (`item_id`),
  KEY `VERTEX_SALES_ORDER_ITEM_INVOICE_TEXT_CODE_INVOICE_TEXT_CODE` (`invoice_text_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Invoice text code from Vertex';

--
-- Table structure for table `vertex_sales_order_item_tax_code`
--

CREATE TABLE `vertex_sales_order_item_tax_code` (
  `item_id` int(11) NOT NULL COMMENT 'Creditmemo Item ID',
  `tax_code` varchar(100) NOT NULL COMMENT 'Invoice text code from Vertex',
  UNIQUE KEY `VERTEX_SALES_ORDER_ITEM_TAX_CODE_ITEM_ID_TAX_CODE` (`item_id`,`tax_code`),
  KEY `VERTEX_SALES_ORDER_ITEM_TAX_CODE_ITEM_ID` (`item_id`),
  KEY `VERTEX_SALES_ORDER_ITEM_TAX_CODE_TAX_CODE` (`tax_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Invoice tax code from Vertex';

--
-- Table structure for table `vertex_sales_order_item_vertex_tax_code`
--

CREATE TABLE `vertex_sales_order_item_vertex_tax_code` (
  `item_id` int(11) NOT NULL COMMENT 'Creditmemo Item ID',
  `vertex_tax_code` varchar(100) NOT NULL COMMENT 'Invoice text code from Vertex',
  UNIQUE KEY `VERTEX_SALES_ORDER_ITEM_VERTEX_TAX_CODE_ITEM_ID_VERTEX_TAX_CODE` (`item_id`,`vertex_tax_code`),
  KEY `VERTEX_SALES_ORDER_ITEM_VERTEX_TAX_CODE_ITEM_ID` (`item_id`),
  KEY `VERTEX_SALES_ORDER_ITEM_VERTEX_TAX_CODE_VERTEX_TAX_CODE` (`vertex_tax_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Invoice Vertex tax code from Vertex';

--
-- Table structure for table `vertex_taxrequest`
--

CREATE TABLE `vertex_taxrequest` (
  `request_id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT 'Request Id',
  `request_type` varchar(255) NOT NULL COMMENT 'Request type',
  `response_time` int(10) unsigned NOT NULL COMMENT 'Milliseconds taken for Vertex API call to complete',
  `quote_id` bigint(20) NOT NULL COMMENT 'Quote Id',
  `order_id` bigint(20) NOT NULL COMMENT 'Order Id',
  `total_tax` varchar(255) NOT NULL COMMENT 'Total Tax Amount',
  `source_path` varchar(255) NOT NULL COMMENT 'Source path controller_module_action',
  `tax_area_id` varchar(255) NOT NULL COMMENT 'Tax Jurisdictions Id',
  `sub_total` varchar(255) NOT NULL COMMENT 'Response Subtotal Amount',
  `total` varchar(255) NOT NULL COMMENT 'Response Total Amount',
  `lookup_result` varchar(255) NOT NULL COMMENT 'Tax Area Response Lookup Result',
  `request_date` timestamp NOT NULL DEFAULT current_timestamp() COMMENT 'Request create date',
  `request_xml` text NOT NULL COMMENT 'Request XML',
  `response_xml` text NOT NULL COMMENT 'Response XML',
  `module_name` varchar(255) NOT NULL COMMENT 'Request module name',
  `module_version` varchar(255) NOT NULL COMMENT 'Request module version',
  PRIMARY KEY (`request_id`),
  UNIQUE KEY `VERTEX_TAXREQUEST_REQUEST_ID` (`request_id`),
  KEY `VERTEX_TAXREQUEST_REQUEST_TYPE` (`request_type`),
  KEY `VERTEX_TAXREQUEST_ORDER_ID` (`order_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='The tax request table';

--
-- Table structure for table `vertex_vat_country_code`
--

CREATE TABLE `vertex_vat_country_code` (
  `address_id` int(10) unsigned NOT NULL COMMENT 'Address ID',
  `customer_country` varchar(255) DEFAULT NULL COMMENT 'Customer Country',
  PRIMARY KEY (`address_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Vat Country code associated to Order Address';

--
-- Table structure for table `weee_tax`
--

CREATE TABLE `weee_tax` (
  `value_id` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Value ID',
  `website_id` smallint(5) unsigned NOT NULL DEFAULT 0 COMMENT 'Website ID',
  `entity_id` int(10) unsigned NOT NULL DEFAULT 0 COMMENT 'Entity ID',
  `country` varchar(2) DEFAULT NULL COMMENT 'Country',
  `value` decimal(12,4) NOT NULL DEFAULT 0.0000 COMMENT 'Value',
  `state` int(11) NOT NULL DEFAULT 0 COMMENT 'State',
  `attribute_id` smallint(5) unsigned NOT NULL COMMENT 'Attribute ID',
  PRIMARY KEY (`value_id`),
  KEY `WEEE_TAX_WEBSITE_ID` (`website_id`),
  KEY `WEEE_TAX_ENTITY_ID` (`entity_id`),
  KEY `WEEE_TAX_COUNTRY` (`country`),
  KEY `WEEE_TAX_ATTRIBUTE_ID` (`attribute_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Weee Tax';

--
-- Table structure for table `widget`
--

CREATE TABLE `widget` (
  `widget_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Widget ID',
  `widget_code` varchar(255) DEFAULT NULL COMMENT 'Widget code for template directive',
  `widget_type` varchar(255) DEFAULT NULL COMMENT 'Widget Type',
  `parameters` text DEFAULT NULL COMMENT 'Parameters',
  PRIMARY KEY (`widget_id`),
  KEY `WIDGET_WIDGET_CODE` (`widget_code`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Preconfigured Widgets';

--
-- Table structure for table `widget_instance`
--

CREATE TABLE `widget_instance` (
  `instance_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Instance ID',
  `instance_type` varchar(255) DEFAULT NULL COMMENT 'Instance Type',
  `theme_id` int(10) unsigned NOT NULL COMMENT 'Theme ID',
  `title` varchar(255) DEFAULT NULL COMMENT 'Widget Title',
  `store_ids` varchar(255) NOT NULL DEFAULT '0' COMMENT 'Store ids',
  `widget_parameters` text DEFAULT NULL COMMENT 'Widget parameters',
  `sort_order` smallint(5) unsigned NOT NULL DEFAULT 0 COMMENT 'Sort order',
  PRIMARY KEY (`instance_id`),
  KEY `WIDGET_INSTANCE_THEME_ID_THEME_THEME_ID` (`theme_id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='Instances of Widget for Package Theme';

--
-- Table structure for table `widget_instance_page`
--

CREATE TABLE `widget_instance_page` (
  `page_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Page ID',
  `instance_id` int(10) unsigned NOT NULL DEFAULT 0 COMMENT 'Instance ID',
  `page_group` varchar(25) DEFAULT NULL COMMENT 'Block Group Type',
  `layout_handle` varchar(255) DEFAULT NULL COMMENT 'Layout Handle',
  `block_reference` varchar(255) DEFAULT NULL COMMENT 'Container',
  `page_for` varchar(25) DEFAULT NULL COMMENT 'For instance entities',
  `entities` text DEFAULT NULL COMMENT 'Catalog entities (comma separated)',
  `page_template` varchar(255) DEFAULT NULL COMMENT 'Path to widget template',
  PRIMARY KEY (`page_id`),
  KEY `WIDGET_INSTANCE_PAGE_INSTANCE_ID` (`instance_id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='Instance of Widget on Page';

--
-- Table structure for table `widget_instance_page_layout`
--

CREATE TABLE `widget_instance_page_layout` (
  `page_id` int(10) unsigned NOT NULL DEFAULT 0 COMMENT 'Page ID',
  `layout_update_id` int(10) unsigned NOT NULL DEFAULT 0 COMMENT 'Layout Update ID',
  PRIMARY KEY (`layout_update_id`,`page_id`),
  KEY `WIDGET_INSTANCE_PAGE_LAYOUT_PAGE_ID` (`page_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Layout updates';

--
-- Table structure for table `wishlist`
--

CREATE TABLE `wishlist` (
  `wishlist_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Wishlist ID',
  `customer_id` int(10) unsigned NOT NULL DEFAULT 0 COMMENT 'Customer ID',
  `shared` smallint(5) unsigned NOT NULL DEFAULT 0 COMMENT 'Sharing flag (0 or 1)',
  `sharing_code` varchar(32) DEFAULT NULL COMMENT 'Sharing encrypted code',
  `updated_at` timestamp NULL DEFAULT NULL COMMENT 'Last updated date',
  PRIMARY KEY (`wishlist_id`),
  UNIQUE KEY `WISHLIST_CUSTOMER_ID` (`customer_id`),
  KEY `WISHLIST_SHARED` (`shared`)
) ENGINE=InnoDB AUTO_INCREMENT=36 DEFAULT CHARSET=utf8 COMMENT='Wishlist main Table';

--
-- Dumping data for table `wishlist`
--

INSERT INTO `wishlist` VALUES ('1','1',0,'5NkWPWTuWQ25tObFbAoIULghrVe24RNh','2019-04-06 08:55:55'),('2','2',0,'SeDsSPZOOMDPNpTbvWWI3UBK4ItqR9BN','2019-06-25 01:58:20'),('3','3',0,'6GKD1qrYdvMm9h6DHY4qWEGyNNMyJV4i','2019-07-04 03:03:42'),('4','4',0,'UZ8IIx9oXxePD1HWB4smCms9SKIYSSvm','2019-08-22 09:53:51'),('5','5',0,'QZTeqP2VU6oXzxUNs7eyuDYn0dJT5wsW','2019-09-18 03:11:48'),('6','6',0,'pci4gf7V8nrN1gAvPxBwu8VqvA650OYy','2021-03-04 03:17:10'),('7','7',0,'5IRzk3hv5izco6xpmpZldWQa270PwXvk','2021-03-16 07:57:12'),('8','8',0,'ljdSY4V4fgxXvQE4navaptPxI5eH9NTp','2021-03-16 08:51:46'),('10','10',0,'wgx9W9mYPRBK7SRbA693A2NLXVvOKjjS','2021-04-28 10:14:49'),('11','11',0,'kYiK14mulTO4HvVgxQHT1s0mYm1Y4EbH','2021-06-24 07:39:59'),('12','12',0,'PD9xJ0UvdaCRgYvW5yhLdbLqFYq5plEA','2021-06-28 07:23:07'),('13','13',0,'wwBVvessLE5XWkFYehvcYXuywftsHLpb','2021-11-27 14:02:02'),('14','14',0,'v1dqr1Ry92BVJbN2cLhZNRe2LgRX7ids','2021-12-07 01:19:15'),('15','15',0,'m3AcD8RsKspDWO0ElZhgW2GegZGlBepY','2021-12-07 01:27:16'),('16','16',0,'zD5heA1Z9dJYHWcMh0stSrrZoyLtjANO','2021-12-31 07:26:35'),('17','17',0,'G0Uj7YYqMIkvm2Jvx9WNvsG7HTqiPG1Q','2021-12-31 07:50:50'),('18','18',0,'OOj9wi2JwFjRLcLstKtx9mpvvJbsrWjd','2022-01-07 05:18:49'),('19','19',0,'HcaEjYn8LhYM8hkMT4r0sofwyGOXNprI','2022-01-18 10:19:24'),('20','20',0,'vRNhtPWKH8wYzeTKUieam1entUoTEsHR','2022-01-21 05:52:30'),('21','21',0,'Jm8s8YEDNyQOjaBm7cqR0m8FtVm699v9','2022-01-23 20:40:21'),('22','22',0,'fLLsPnqPhDu4ssF9auJhvOL9dGnapeUm','2022-01-24 16:16:22'),('23','23',0,'rujITCYBor5CHTurrCvkBuKeDJd5qqVA','2022-01-26 10:47:42'),('24','24',0,'qdPBMJCHKDcNik9iMgxppPax9LlKi737','2022-02-01 05:18:32'),('25','25',0,'tmVhWDRjZbRUVpcxDDloWN4pvG75G0ne','2022-02-10 08:52:47'),('26','26',0,'4eOkSahq4SvlMQXsdfrdZMkgOYX9CdX0','2022-02-15 10:51:50'),('27','27',0,'hqe4tIvlkYSbIxcPJcdqry1zEkqPDmEx','2022-02-19 15:37:51'),('28','28',0,'qtvfr60wxXP0DP3hLEKCnfwKWVvqjq56','2022-03-08 09:49:10'),('29','29',0,'QANBYlStALQtd5SYSXccFe3UQaLCbch0','2022-03-17 09:58:02'),('30','30',0,'4OWbLE9T5QW8hGgDKlx6BmQ1pY4EKVNP','2022-03-18 07:01:36'),('31','31',0,'dOwlZEk6DQpZE7KqppdTyAlEmvGc0ZB3','2022-04-02 02:36:08'),('32','32',0,'2mH5MEMqVM7IiYfmvvFS6Qsg1gWglHUj','2022-04-02 10:03:41'),('33','33',0,'2LQkLZfWDaPLyAlHWa0ZZsYCwdL9vf9F','2022-04-26 06:54:30'),('34','34',0,'oh7LvSZL98c74vnXuXE6nwDOL0oL6JfF','2022-05-10 12:10:22'),('35','35',0,'c2oa4gvNCHCCyWVHT1ejwaS8TeCh6z8T','2022-05-17 11:18:00');

--
-- Table structure for table `wishlist_item`
--

CREATE TABLE `wishlist_item` (
  `wishlist_item_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Wishlist item ID',
  `wishlist_id` int(10) unsigned NOT NULL DEFAULT 0 COMMENT 'Wishlist ID',
  `product_id` int(10) unsigned NOT NULL DEFAULT 0 COMMENT 'Product ID',
  `store_id` smallint(5) unsigned DEFAULT NULL COMMENT 'Store ID',
  `added_at` timestamp NULL DEFAULT NULL COMMENT 'Add date and time',
  `description` text DEFAULT NULL COMMENT 'Short description of wish list item',
  `qty` decimal(12,4) NOT NULL COMMENT 'Qty',
  PRIMARY KEY (`wishlist_item_id`),
  KEY `WISHLIST_ITEM_WISHLIST_ID` (`wishlist_id`),
  KEY `WISHLIST_ITEM_PRODUCT_ID` (`product_id`),
  KEY `WISHLIST_ITEM_STORE_ID` (`store_id`)
) ENGINE=InnoDB AUTO_INCREMENT=64 DEFAULT CHARSET=utf8 COMMENT='Wishlist items';

--
-- Dumping data for table `wishlist_item`
--

INSERT INTO `wishlist_item` VALUES ('3','1','105',1,'2019-04-06 09:00:09',NULL,'2.0000'),('13','6','3',1,'2021-03-05 04:52:02',NULL,'1.0000'),('15','6','286',1,'2021-03-05 04:53:23',NULL,'1.0000'),('22','8','344',1,'2021-04-24 03:03:24',NULL,'11.0000'),('23','8','343',1,'2021-04-24 03:04:14',NULL,'1.0000'),('24','8','346',1,'2021-04-24 03:04:45',NULL,'6.0000'),('31','10','344',1,'2021-05-02 12:59:06',NULL,'4.0000'),('32','10','343',1,'2021-05-04 01:39:19',NULL,'3.0000'),('33','10','342',1,'2021-05-19 13:49:13',NULL,'6.0000'),('34','10','346',1,'2021-05-19 15:53:31',NULL,'2.0000'),('35','8','342',1,'2021-06-03 10:59:23',NULL,'4.0000'),('36','7','138',1,'2021-06-24 07:57:13',NULL,'1.0000'),('37','7','139',1,'2021-06-24 07:57:18',NULL,'1.0000'),('38','7','286',1,'2021-06-24 07:57:23',NULL,'1.0000'),('39','7','287',1,'2021-06-24 07:57:28',NULL,'1.0000'),('40','7','3',1,'2021-06-24 07:57:36',NULL,'2.0000'),('41','7','12',1,'2021-06-24 07:57:40',NULL,'1.0000'),('42','7','70',1,'2021-06-24 07:57:45',NULL,'1.0000'),('43','7','1',1,'2021-06-24 07:57:50',NULL,'1.0000'),('44','7','323',1,'2021-06-24 07:59:06',NULL,'1.0000'),('45','12','344',1,'2021-06-29 04:12:40',NULL,'1.0000'),('46','8','70',1,'2021-07-07 10:20:41',NULL,'1.0000'),('47','10','12',1,'2021-07-08 02:03:34',NULL,'1.0000'),('48','8','322',1,'2021-07-08 04:12:35',NULL,'1.0000'),('49','8','345',1,'2021-07-08 05:07:22',NULL,'1.0000'),('50','8','3',1,'2021-07-08 05:08:22',NULL,'2.0000'),('51','2','343',1,'2021-07-08 06:15:40',NULL,'1.0000'),('52','2','344',1,'2021-07-08 06:16:01',NULL,'2.0000'),('53','8','347',1,'2021-11-16 08:07:58',NULL,'1.0000'),('54','23','340',1,'2022-01-26 10:48:06',NULL,'1.0000'),('55','23','342',1,'2022-01-26 10:48:07',NULL,'1.0000'),('56','23','344',1,'2022-01-26 10:48:08',NULL,'1.0000'),('57','23','346',1,'2022-01-26 10:48:10',NULL,'1.0000'),('58','23','368',1,'2022-01-26 10:48:11',NULL,'1.0000'),('59','31','1',7,'2022-04-02 03:00:42',NULL,'1.0000'),('60','31','12',7,'2022-04-02 03:00:52',NULL,'1.0000'),('61','31','70',7,'2022-04-02 03:01:08',NULL,'1.0000'),('62','32','1',1,'2022-04-02 10:04:00',NULL,'1.0000'),('63','34','3',5,'2022-05-10 12:10:43',NULL,'1.0000');

--
-- Table structure for table `wishlist_item_option`
--

CREATE TABLE `wishlist_item_option` (
  `option_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Option ID',
  `wishlist_item_id` int(10) unsigned NOT NULL COMMENT 'Wishlist Item ID',
  `product_id` int(10) unsigned NOT NULL COMMENT 'Product ID',
  `code` varchar(255) NOT NULL COMMENT 'Code',
  `value` text DEFAULT NULL COMMENT 'Value',
  PRIMARY KEY (`option_id`),
  KEY `FK_A014B30B04B72DD0EAB3EECD779728D6` (`wishlist_item_id`),
  KEY `WISHLIST_ITEM_OPTION_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` (`product_id`)
) ENGINE=InnoDB AUTO_INCREMENT=84 DEFAULT CHARSET=utf8 COMMENT='Wishlist Item Option Table';

--
-- Dumping data for table `wishlist_item_option`
--

INSERT INTO `wishlist_item_option` VALUES ('6','3','105','info_buyRequest','{\"product\":\"105\",\"uenc\":\"aHR0cDovL3dwMmNhcnQuY29tL2dlY2tvLw,,\",\"form_key\":\"fi5qdAJXk3MXPLWH\"}'),('7','3','105','bundle_identity','105'),('8','3','105','bundle_option_ids','[1,2,3]'),('9','3','105','bundle_selection_ids','[]'),('19','13','3','info_buyRequest','{\"product\":\"3\",\"uenc\":\"aHR0cHM6Ly93cDJjYXJ0LmNvbS90dXJhbi9kZWZhdWx0Lw,,\",\"form_key\":\"dQjWyW1jYOH7cdjN\"}'),('21','15','286','info_buyRequest','{\"product\":\"286\",\"uenc\":\"aHR0cHM6Ly93cDJjYXJ0LmNvbS90dXJhbi9kZWZhdWx0Lw,,\",\"form_key\":\"dQjWyW1jYOH7cdjN\"}'),('22','15','286','downloadable_link_ids','1'),('32','22','344','info_buyRequest','{\"product\":\"344\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhLw,,\",\"form_key\":\"AouSKqcbaeaucssd\"}'),('33','23','343','info_buyRequest','{\"product\":\"343\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhLw,,\",\"form_key\":\"AouSKqcbaeaucssd\"}'),('34','24','346','product_type','grouped'),('35','24','346','info_buyRequest','{\"product\":\"346\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhLw,,\",\"form_key\":\"AouSKqcbaeaucssd\",\"original_qty\":4,\"qty\":5,\"super_group\":null}'),('45','31','344','info_buyRequest','{\"product\":\"344\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQv\",\"form_key\":\"KrkrKxP8ILzDfNXH\"}'),('46','32','343','info_buyRequest','{\"product\":\"343\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQv\",\"form_key\":\"KrkrKxP8ILzDfNXH\"}'),('47','33','342','info_buyRequest','{\"product\":\"342\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQv\",\"form_key\":\"KrkrKxP8ILzDfNXH\"}'),('48','34','346','product_type','grouped'),('49','34','346','info_buyRequest','{\"product\":\"346\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQv\",\"form_key\":\"KrkrKxP8ILzDfNXH\",\"original_qty\":null,\"qty\":1,\"super_group\":null}'),('50','35','342','info_buyRequest','{\"product\":\"342\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQv\",\"form_key\":\"U9rcYPoG9qOZCIZa\"}'),('51','36','138','info_buyRequest','{\"product\":\"138\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('52','37','139','info_buyRequest','{\"product\":\"139\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('53','38','286','info_buyRequest','{\"product\":\"286\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('54','38','286','downloadable_link_ids','1'),('55','39','287','info_buyRequest','{\"product\":\"287\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('56','40','3','info_buyRequest','{\"product\":\"3\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('57','41','12','info_buyRequest','{\"product\":\"12\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('58','42','70','info_buyRequest','{\"product\":\"70\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('59','43','1','info_buyRequest','{\"product\":\"1\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('60','44','323','info_buyRequest','{\"product\":\"323\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"QPx6wYd7FVv4XVKc\"}'),('61','45','344','info_buyRequest','{\"product\":\"344\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhLw,,\",\"form_key\":\"IpL5u4rz4wXH6i9t\"}'),('62','46','70','info_buyRequest','{\"product\":\"70\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"roqqbulXIfObYBpy\",\"action\":\"add\"}'),('63','47','12','info_buyRequest','{\"product\":\"12\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"ias25PtVpIxtxQyD\",\"action\":\"add\"}'),('64','48','322','info_buyRequest','{\"product\":\"322\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhLw,,\",\"form_key\":\"d5bQnGMyUf7kHqxt\",\"action\":\"add\"}'),('65','49','345','info_buyRequest','{\"product\":\"345\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQv\",\"form_key\":\"d5bQnGMyUf7kHqxt\",\"action\":\"add\"}'),('66','50','3','info_buyRequest','{\"product\":\"3\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhL2RlZmF1bHQvc2hvcC5odG1s\",\"form_key\":\"d5bQnGMyUf7kHqxt\",\"action\":\"add\"}'),('67','51','343','info_buyRequest','{\"product\":\"343\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhLw,,\",\"form_key\":\"A9phQRawbzuzPI2Y\",\"action\":\"add\"}'),('68','52','344','info_buyRequest','{\"product\":\"344\",\"uenc\":\"aHR0cHM6Ly9tYWdpY2NhcnQuaW8vc2FmaXJhLw,,\",\"form_key\":\"A9phQRawbzuzPI2Y\",\"action\":\"add\"}'),('69','53','347','info_buyRequest','{\"product\":\"347\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9kZWZhdWx0Lw,,\",\"form_key\":\"m1N4BrPBViGfF1sz\",\"action\":\"add\"}'),('70','53','347','bundle_identity','347'),('71','53','347','bundle_option_ids','[15,16]'),('72','53','347','bundle_selection_ids','[]'),('73','54','340','info_buyRequest','{\"product\":\"340\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9kZWZhdWx0Lw,,\",\"form_key\":\"s8qPlJdA5Czq6wHQ\",\"action\":\"add\"}'),('74','55','342','info_buyRequest','{\"product\":\"342\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9kZWZhdWx0Lw,,\",\"form_key\":\"s8qPlJdA5Czq6wHQ\",\"action\":\"add\"}'),('75','56','344','info_buyRequest','{\"product\":\"344\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9kZWZhdWx0Lw,,\",\"form_key\":\"s8qPlJdA5Czq6wHQ\",\"action\":\"add\"}'),('76','57','346','product_type','grouped'),('77','57','346','info_buyRequest','{\"product\":\"346\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9kZWZhdWx0Lw,,\",\"form_key\":\"s8qPlJdA5Czq6wHQ\",\"action\":\"add\"}'),('78','58','368','info_buyRequest','{\"product\":\"368\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9kZWZhdWx0Lw,,\",\"form_key\":\"s8qPlJdA5Czq6wHQ\",\"action\":\"add\"}'),('79','59','1','info_buyRequest','{\"product\":\"1\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9lbmdsaXNoXzQvYWNjZXNzb3JpZXMuaHRtbA,,\",\"form_key\":\"fbevxUjK4RvkHFIb\",\"action\":\"add\"}'),('80','60','12','info_buyRequest','{\"product\":\"12\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9lbmdsaXNoXzQvYWNjZXNzb3JpZXMuaHRtbA,,\",\"form_key\":\"fbevxUjK4RvkHFIb\",\"action\":\"add\"}'),('81','61','70','info_buyRequest','{\"product\":\"70\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9lbmdsaXNoXzQvYWNjZXNzb3JpZXMuaHRtbA,,\",\"form_key\":\"fbevxUjK4RvkHFIb\",\"action\":\"add\"}'),('82','62','1','info_buyRequest','{\"product\":\"1\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9kZWZhdWx0L2NoYWlycy5odG1s\",\"form_key\":\"ge3cYaXQ1iue7N8I\",\"action\":\"add\"}'),('83','63','3','info_buyRequest','{\"product\":\"3\",\"uenc\":\"aHR0cHM6Ly9tMi5hbG90aGVtZXMuY29tL3NhZmlyYS9lbmdsaXNoXzMvc2hvcC9ob21lLWRlY29yL2NoYWlycy1zb2Zhcy5odG1s\",\"form_key\":\"GMywyHyDzOnUc1tT\",\"action\":\"add\"}');

--
-- Table structure for table `yotpo_order_status_history`
--

CREATE TABLE `yotpo_order_status_history` (
  `id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Id',
  `order_id` int(10) unsigned DEFAULT NULL COMMENT 'Order Id',
  `store_id` int(10) unsigned DEFAULT NULL COMMENT 'Store Id',
  `old_status` varchar(32) DEFAULT NULL COMMENT 'Old Status',
  `new_status` varchar(32) DEFAULT NULL COMMENT 'New Status',
  `created_at` datetime DEFAULT NULL COMMENT 'Created At',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8 COMMENT='yotpo_order_status_history';

--
-- Dumping data for table `yotpo_order_status_history`
--

INSERT INTO `yotpo_order_status_history` VALUES ('1','65','9',NULL,'pending','2022-02-19 15:39:41'),('2','66','1',NULL,'pending','2022-03-08 13:09:01'),('3','67','7',NULL,'pending','2022-03-11 03:55:32'),('4','68','1',NULL,'pending','2022-03-18 19:50:15'),('5','69','7',NULL,'pending','2022-03-30 10:47:58'),('6','70','7',NULL,'pending','2022-03-31 01:44:52'),('7','71','7',NULL,'pending','2022-04-26 05:56:42'),('8','72','5',NULL,'pending','2022-05-10 12:08:51'),('9','73','5',NULL,'pending','2022-05-10 12:20:47'),('10','74','13',NULL,'pending','2022-05-10 12:22:22');

--
-- Table structure for table `yotpo_rich_snippets`
--

CREATE TABLE `yotpo_rich_snippets` (
  `rich_snippet_id` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Id',
  `product_id` int(11) NOT NULL COMMENT 'Product Id',
  `store_id` int(11) NOT NULL COMMENT 'Store Id',
  `average_score` decimal(10,2) DEFAULT NULL COMMENT 'Average Score',
  `reviews_count` float(10,0) NOT NULL COMMENT 'Reviews Count',
  `expiration_time` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp() COMMENT 'Expiry Time',
  PRIMARY KEY (`rich_snippet_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='yotpo_rich_snippets';

--
-- Table structure for table `yotpo_sync`
--

CREATE TABLE `yotpo_sync` (
  `sync_id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Id',
  `store_id` int(10) unsigned DEFAULT NULL COMMENT 'Store ID',
  `entity_type` varchar(50) DEFAULT NULL COMMENT 'Entity Type',
  `entity_id` int(10) unsigned DEFAULT NULL COMMENT 'Entity ID',
  `sync_flag` smallint(6) DEFAULT 0 COMMENT 'Sync Flag',
  `sync_date` datetime NOT NULL COMMENT 'Sync Date',
  PRIMARY KEY (`sync_id`),
  UNIQUE KEY `YOTPO_SYNC_STORE_ID_ENTITY_TYPE_ENTITY_ID` (`store_id`,`entity_type`,`entity_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='yotpo_sync';

--
-- Structure for view `inventory_stock_1`
--

DROP VIEW IF EXISTS `inventory_stock_1`;
CREATE ALGORITHM=UNDEFINED SQL SECURITY INVOKER VIEW `inventory_stock_1` AS select distinct `legacy_stock_status`.`product_id` AS `product_id`,`legacy_stock_status`.`website_id` AS `website_id`,`legacy_stock_status`.`stock_id` AS `stock_id`,`legacy_stock_status`.`qty` AS `quantity`,`legacy_stock_status`.`stock_status` AS `is_salable`,`product`.`sku` AS `sku` from (`cataloginventory_stock_status` `legacy_stock_status` join `catalog_product_entity` `product` on(`legacy_stock_status`.`product_id` = `product`.`entity_id`));

ALTER TABLE `admin_passwords`
  ADD CONSTRAINT `ADMIN_PASSWORDS_USER_ID_ADMIN_USER_USER_ID` FOREIGN KEY (`user_id`) REFERENCES `admin_user` (`user_id`) ON DELETE CASCADE;

ALTER TABLE `admin_user_expiration`
  ADD CONSTRAINT `ADMIN_USER_EXPIRATION_USER_ID_ADMIN_USER_USER_ID` FOREIGN KEY (`user_id`) REFERENCES `admin_user` (`user_id`) ON DELETE CASCADE;

ALTER TABLE `admin_user_session`
  ADD CONSTRAINT `ADMIN_USER_SESSION_USER_ID_ADMIN_USER_USER_ID` FOREIGN KEY (`user_id`) REFERENCES `admin_user` (`user_id`) ON DELETE CASCADE;

ALTER TABLE `adobe_stock_asset`
  ADD CONSTRAINT `ADOBE_STOCK_ASSET_CATEGORY_ID_ADOBE_STOCK_CATEGORY_ID` FOREIGN KEY (`category_id`) REFERENCES `adobe_stock_category` (`id`) ON DELETE SET NULL,
  ADD CONSTRAINT `ADOBE_STOCK_ASSET_CREATOR_ID_ADOBE_STOCK_CREATOR_ID` FOREIGN KEY (`creator_id`) REFERENCES `adobe_stock_creator` (`id`) ON DELETE SET NULL,
  ADD CONSTRAINT `ADOBE_STOCK_ASSET_MEDIA_GALLERY_ID_MEDIA_GALLERY_ASSET_ID` FOREIGN KEY (`media_gallery_id`) REFERENCES `media_gallery_asset` (`id`) ON DELETE CASCADE;

ALTER TABLE `adobe_user_profile`
  ADD CONSTRAINT `ADOBE_USER_PROFILE_ADMIN_USER_ID_ADMIN_USER_USER_ID` FOREIGN KEY (`admin_user_id`) REFERENCES `admin_user` (`user_id`) ON DELETE CASCADE;

ALTER TABLE `amazon_customer`
  ADD CONSTRAINT `AMAZON_CUSTOMER_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `amazon_quote`
  ADD CONSTRAINT `AMAZON_QUOTE_QUOTE_ID_QUOTE_ENTITY_ID` FOREIGN KEY (`quote_id`) REFERENCES `quote` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `amazon_sales_order`
  ADD CONSTRAINT `AMAZON_SALES_ORDER_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `authorization_rule`
  ADD CONSTRAINT `AUTHORIZATION_RULE_ROLE_ID_AUTHORIZATION_ROLE_ROLE_ID` FOREIGN KEY (`role_id`) REFERENCES `authorization_role` (`role_id`) ON DELETE CASCADE;

ALTER TABLE `braintree_transaction_details`
  ADD CONSTRAINT `BRAINTREE_TRANSACTION_DETAILS_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_category_entity_datetime`
  ADD CONSTRAINT `CATALOG_CATEGORY_ENTITY_DATETIME_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_DTIME_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_DTIME_ENTT_ID_CAT_CTGR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_category_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_category_entity_decimal`
  ADD CONSTRAINT `CATALOG_CATEGORY_ENTITY_DECIMAL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_DEC_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_DEC_ENTT_ID_CAT_CTGR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_category_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_category_entity_int`
  ADD CONSTRAINT `CATALOG_CATEGORY_ENTITY_INT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_INT_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_INT_ENTT_ID_CAT_CTGR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_category_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_category_entity_text`
  ADD CONSTRAINT `CATALOG_CATEGORY_ENTITY_TEXT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_TEXT_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_TEXT_ENTT_ID_CAT_CTGR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_category_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_category_entity_varchar`
  ADD CONSTRAINT `CATALOG_CATEGORY_ENTITY_VARCHAR_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_VCHR_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_ENTT_VCHR_ENTT_ID_CAT_CTGR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_category_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_category_product`
  ADD CONSTRAINT `CAT_CTGR_PRD_CTGR_ID_CAT_CTGR_ENTT_ENTT_ID` FOREIGN KEY (`category_id`) REFERENCES `catalog_category_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_CTGR_PRD_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_compare_item`
  ADD CONSTRAINT `CATALOG_COMPARE_ITEM_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CATALOG_COMPARE_ITEM_LIST_ID_CATALOG_COMPARE_LIST_LIST_ID` FOREIGN KEY (`list_id`) REFERENCES `catalog_compare_list` (`list_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CATALOG_COMPARE_ITEM_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CATALOG_COMPARE_ITEM_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `catalog_compare_list`
  ADD CONSTRAINT `CATALOG_COMPARE_LIST_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_eav_attribute`
  ADD CONSTRAINT `CATALOG_EAV_ATTRIBUTE_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_bundle_option`
  ADD CONSTRAINT `CAT_PRD_BNDL_OPT_PARENT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`parent_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_bundle_option_value`
  ADD CONSTRAINT `CAT_PRD_BNDL_OPT_VAL_OPT_ID_CAT_PRD_BNDL_OPT_OPT_ID` FOREIGN KEY (`option_id`) REFERENCES `catalog_product_bundle_option` (`option_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_bundle_price_index`
  ADD CONSTRAINT `CAT_PRD_BNDL_PRICE_IDX_CSTR_GROUP_ID_CSTR_GROUP_CSTR_GROUP_ID` FOREIGN KEY (`customer_group_id`) REFERENCES `customer_group` (`customer_group_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_BNDL_PRICE_IDX_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_BNDL_PRICE_IDX_WS_ID_STORE_WS_WS_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_bundle_selection`
  ADD CONSTRAINT `CAT_PRD_BNDL_SELECTION_OPT_ID_CAT_PRD_BNDL_OPT_OPT_ID` FOREIGN KEY (`option_id`) REFERENCES `catalog_product_bundle_option` (`option_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_BNDL_SELECTION_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_bundle_selection_price`
  ADD CONSTRAINT `CAT_PRD_BNDL_SELECTION_PRICE_WS_ID_STORE_WS_WS_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_DCF37523AA05D770A70AA4ED7C2616E4` FOREIGN KEY (`selection_id`) REFERENCES `catalog_product_bundle_selection` (`selection_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_datetime`
  ADD CONSTRAINT `CATALOG_PRODUCT_ENTITY_DATETIME_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_DTIME_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_DTIME_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_decimal`
  ADD CONSTRAINT `CATALOG_PRODUCT_ENTITY_DECIMAL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_DEC_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_DEC_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_gallery`
  ADD CONSTRAINT `CATALOG_PRODUCT_ENTITY_GALLERY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_GLR_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_GLR_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_int`
  ADD CONSTRAINT `CATALOG_PRODUCT_ENTITY_INT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_INT_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_INT_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_media_gallery`
  ADD CONSTRAINT `CAT_PRD_ENTT_MDA_GLR_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_media_gallery_value`
  ADD CONSTRAINT `CAT_PRD_ENTT_MDA_GLR_VAL_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_MDA_GLR_VAL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_MDA_GLR_VAL_VAL_ID_CAT_PRD_ENTT_MDA_GLR_VAL_ID` FOREIGN KEY (`value_id`) REFERENCES `catalog_product_entity_media_gallery` (`value_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_media_gallery_value_to_entity`
  ADD CONSTRAINT `CAT_PRD_ENTT_MDA_GLR_VAL_TO_ENTT_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_A6C6C8FAA386736921D3A7C4B50B1185` FOREIGN KEY (`value_id`) REFERENCES `catalog_product_entity_media_gallery` (`value_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_media_gallery_value_video`
  ADD CONSTRAINT `CAT_PRD_ENTT_MDA_GLR_VAL_VIDEO_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_6FDF205946906B0E653E60AA769899F8` FOREIGN KEY (`value_id`) REFERENCES `catalog_product_entity_media_gallery` (`value_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_text`
  ADD CONSTRAINT `CATALOG_PRODUCT_ENTITY_TEXT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_TEXT_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_TEXT_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_tier_price`
  ADD CONSTRAINT `CAT_PRD_ENTT_TIER_PRICE_CSTR_GROUP_ID_CSTR_GROUP_CSTR_GROUP_ID` FOREIGN KEY (`customer_group_id`) REFERENCES `customer_group` (`customer_group_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_TIER_PRICE_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_TIER_PRICE_WS_ID_STORE_WS_WS_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_entity_varchar`
  ADD CONSTRAINT `CATALOG_PRODUCT_ENTITY_VARCHAR_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_VCHR_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_ENTT_VCHR_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_frontend_action`
  ADD CONSTRAINT `CAT_PRD_FRONTEND_ACTION_CSTR_ID_CSTR_ENTT_ENTT_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_FRONTEND_ACTION_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_index_tier_price`
  ADD CONSTRAINT `CAT_PRD_IDX_TIER_PRICE_CSTR_GROUP_ID_CSTR_GROUP_CSTR_GROUP_ID` FOREIGN KEY (`customer_group_id`) REFERENCES `customer_group` (`customer_group_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_IDX_TIER_PRICE_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_IDX_TIER_PRICE_WS_ID_STORE_WS_WS_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_index_website`
  ADD CONSTRAINT `CAT_PRD_IDX_WS_WS_ID_STORE_WS_WS_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_link`
  ADD CONSTRAINT `CATALOG_PRODUCT_LINK_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_LNK_LNKED_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`linked_product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_LNK_LNK_TYPE_ID_CAT_PRD_LNK_TYPE_LNK_TYPE_ID` FOREIGN KEY (`link_type_id`) REFERENCES `catalog_product_link_type` (`link_type_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_link_attribute`
  ADD CONSTRAINT `CAT_PRD_LNK_ATTR_LNK_TYPE_ID_CAT_PRD_LNK_TYPE_LNK_TYPE_ID` FOREIGN KEY (`link_type_id`) REFERENCES `catalog_product_link_type` (`link_type_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_link_attribute_decimal`
  ADD CONSTRAINT `CAT_PRD_LNK_ATTR_DEC_LNK_ID_CAT_PRD_LNK_LNK_ID` FOREIGN KEY (`link_id`) REFERENCES `catalog_product_link` (`link_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_AB2EFA9A14F7BCF1D5400056203D14B6` FOREIGN KEY (`product_link_attribute_id`) REFERENCES `catalog_product_link_attribute` (`product_link_attribute_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_link_attribute_int`
  ADD CONSTRAINT `CAT_PRD_LNK_ATTR_INT_LNK_ID_CAT_PRD_LNK_LNK_ID` FOREIGN KEY (`link_id`) REFERENCES `catalog_product_link` (`link_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_D6D878F8BA2A4282F8DDED7E6E3DE35C` FOREIGN KEY (`product_link_attribute_id`) REFERENCES `catalog_product_link_attribute` (`product_link_attribute_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_link_attribute_varchar`
  ADD CONSTRAINT `CAT_PRD_LNK_ATTR_VCHR_LNK_ID_CAT_PRD_LNK_LNK_ID` FOREIGN KEY (`link_id`) REFERENCES `catalog_product_link` (`link_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_DEE9C4DA61CFCC01DFCF50F0D79CEA51` FOREIGN KEY (`product_link_attribute_id`) REFERENCES `catalog_product_link_attribute` (`product_link_attribute_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_option`
  ADD CONSTRAINT `CAT_PRD_OPT_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_option_price`
  ADD CONSTRAINT `CATALOG_PRODUCT_OPTION_PRICE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_OPT_PRICE_OPT_ID_CAT_PRD_OPT_OPT_ID` FOREIGN KEY (`option_id`) REFERENCES `catalog_product_option` (`option_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_option_title`
  ADD CONSTRAINT `CATALOG_PRODUCT_OPTION_TITLE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_OPT_TTL_OPT_ID_CAT_PRD_OPT_OPT_ID` FOREIGN KEY (`option_id`) REFERENCES `catalog_product_option` (`option_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_option_type_price`
  ADD CONSTRAINT `CATALOG_PRODUCT_OPTION_TYPE_PRICE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_B523E3378E8602F376CC415825576B7F` FOREIGN KEY (`option_type_id`) REFERENCES `catalog_product_option_type_value` (`option_type_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_option_type_title`
  ADD CONSTRAINT `CATALOG_PRODUCT_OPTION_TYPE_TITLE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_C085B9CF2C2A302E8043FDEA1937D6A2` FOREIGN KEY (`option_type_id`) REFERENCES `catalog_product_option_type_value` (`option_type_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_option_type_value`
  ADD CONSTRAINT `CAT_PRD_OPT_TYPE_VAL_OPT_ID_CAT_PRD_OPT_OPT_ID` FOREIGN KEY (`option_id`) REFERENCES `catalog_product_option` (`option_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_relation`
  ADD CONSTRAINT `CAT_PRD_RELATION_CHILD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`child_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_RELATION_PARENT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`parent_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_super_attribute`
  ADD CONSTRAINT `CAT_PRD_SPR_ATTR_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_super_attribute_label`
  ADD CONSTRAINT `CATALOG_PRODUCT_SUPER_ATTRIBUTE_LABEL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_309442281DF7784210ED82B2CC51E5D5` FOREIGN KEY (`product_super_attribute_id`) REFERENCES `catalog_product_super_attribute` (`product_super_attribute_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_super_link`
  ADD CONSTRAINT `CAT_PRD_SPR_LNK_PARENT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`parent_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_SPR_LNK_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_product_website`
  ADD CONSTRAINT `CATALOG_PRODUCT_WEBSITE_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_PRD_WS_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `catalog_url_rewrite_product_category`
  ADD CONSTRAINT `CAT_URL_REWRITE_PRD_CTGR_CTGR_ID_CAT_CTGR_ENTT_ENTT_ID` FOREIGN KEY (`category_id`) REFERENCES `catalog_category_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CAT_URL_REWRITE_PRD_CTGR_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_BB79E64705D7F17FE181F23144528FC8` FOREIGN KEY (`url_rewrite_id`) REFERENCES `url_rewrite` (`url_rewrite_id`) ON DELETE CASCADE;

ALTER TABLE `cataloginventory_stock_item`
  ADD CONSTRAINT `CATINV_STOCK_ITEM_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CATINV_STOCK_ITEM_STOCK_ID_CATINV_STOCK_STOCK_ID` FOREIGN KEY (`stock_id`) REFERENCES `cataloginventory_stock` (`stock_id`) ON DELETE CASCADE;

ALTER TABLE `catalogrule_customer_group`
  ADD CONSTRAINT `CATALOGRULE_CUSTOMER_GROUP_RULE_ID_CATALOGRULE_RULE_ID` FOREIGN KEY (`rule_id`) REFERENCES `catalogrule` (`rule_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CATRULE_CSTR_GROUP_CSTR_GROUP_ID_CSTR_GROUP_CSTR_GROUP_ID` FOREIGN KEY (`customer_group_id`) REFERENCES `customer_group` (`customer_group_id`) ON DELETE CASCADE;

ALTER TABLE `catalogrule_website`
  ADD CONSTRAINT `CATALOGRULE_WEBSITE_RULE_ID_CATALOGRULE_RULE_ID` FOREIGN KEY (`rule_id`) REFERENCES `catalogrule` (`rule_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CATALOGRULE_WEBSITE_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `catalogsearch_recommendations`
  ADD CONSTRAINT `CATALOGSEARCH_RECOMMENDATIONS_QUERY_ID_SEARCH_QUERY_QUERY_ID` FOREIGN KEY (`query_id`) REFERENCES `search_query` (`query_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CATALOGSEARCH_RECOMMENDATIONS_RELATION_ID_SEARCH_QUERY_QUERY_ID` FOREIGN KEY (`relation_id`) REFERENCES `search_query` (`query_id`) ON DELETE CASCADE;

ALTER TABLE `checkout_agreement_store`
  ADD CONSTRAINT `CHECKOUT_AGREEMENT_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CHKT_AGRT_STORE_AGRT_ID_CHKT_AGRT_AGRT_ID` FOREIGN KEY (`agreement_id`) REFERENCES `checkout_agreement` (`agreement_id`) ON DELETE CASCADE;

ALTER TABLE `cms_block_store`
  ADD CONSTRAINT `CMS_BLOCK_STORE_BLOCK_ID_CMS_BLOCK_BLOCK_ID` FOREIGN KEY (`block_id`) REFERENCES `cms_block` (`block_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CMS_BLOCK_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `cms_page_store`
  ADD CONSTRAINT `CMS_PAGE_STORE_PAGE_ID_CMS_PAGE_PAGE_ID` FOREIGN KEY (`page_id`) REFERENCES `cms_page` (`page_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CMS_PAGE_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `customer_address_entity`
  ADD CONSTRAINT `CUSTOMER_ADDRESS_ENTITY_PARENT_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_address_entity_datetime`
  ADD CONSTRAINT `CSTR_ADDR_ENTT_DTIME_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CSTR_ADDR_ENTT_DTIME_ENTT_ID_CSTR_ADDR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_address_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_address_entity_decimal`
  ADD CONSTRAINT `CSTR_ADDR_ENTT_DEC_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CSTR_ADDR_ENTT_DEC_ENTT_ID_CSTR_ADDR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_address_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_address_entity_int`
  ADD CONSTRAINT `CSTR_ADDR_ENTT_INT_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CSTR_ADDR_ENTT_INT_ENTT_ID_CSTR_ADDR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_address_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_address_entity_text`
  ADD CONSTRAINT `CSTR_ADDR_ENTT_TEXT_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CSTR_ADDR_ENTT_TEXT_ENTT_ID_CSTR_ADDR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_address_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_address_entity_varchar`
  ADD CONSTRAINT `CSTR_ADDR_ENTT_VCHR_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CSTR_ADDR_ENTT_VCHR_ENTT_ID_CSTR_ADDR_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_address_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_eav_attribute`
  ADD CONSTRAINT `CUSTOMER_EAV_ATTRIBUTE_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE;

ALTER TABLE `customer_eav_attribute_website`
  ADD CONSTRAINT `CSTR_EAV_ATTR_WS_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CSTR_EAV_ATTR_WS_WS_ID_STORE_WS_WS_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `customer_entity`
  ADD CONSTRAINT `CUSTOMER_ENTITY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL,
  ADD CONSTRAINT `CUSTOMER_ENTITY_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE SET NULL;

ALTER TABLE `customer_entity_datetime`
  ADD CONSTRAINT `CUSTOMER_ENTITY_DATETIME_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CUSTOMER_ENTITY_DATETIME_ENTITY_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_entity_decimal`
  ADD CONSTRAINT `CUSTOMER_ENTITY_DECIMAL_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CUSTOMER_ENTITY_DECIMAL_ENTITY_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_entity_int`
  ADD CONSTRAINT `CUSTOMER_ENTITY_INT_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CUSTOMER_ENTITY_INT_ENTITY_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_entity_text`
  ADD CONSTRAINT `CUSTOMER_ENTITY_TEXT_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CUSTOMER_ENTITY_TEXT_ENTITY_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_entity_varchar`
  ADD CONSTRAINT `CUSTOMER_ENTITY_VARCHAR_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `CUSTOMER_ENTITY_VARCHAR_ENTITY_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `customer_form_attribute`
  ADD CONSTRAINT `CUSTOMER_FORM_ATTRIBUTE_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE;

ALTER TABLE `design_change`
  ADD CONSTRAINT `DESIGN_CHANGE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `directory_country_region_name`
  ADD CONSTRAINT `DIR_COUNTRY_REGION_NAME_REGION_ID_DIR_COUNTRY_REGION_REGION_ID` FOREIGN KEY (`region_id`) REFERENCES `directory_country_region` (`region_id`) ON DELETE CASCADE;

ALTER TABLE `downloadable_link`
  ADD CONSTRAINT `DOWNLOADABLE_LINK_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `downloadable_link_price`
  ADD CONSTRAINT `DOWNLOADABLE_LINK_PRICE_LINK_ID_DOWNLOADABLE_LINK_LINK_ID` FOREIGN KEY (`link_id`) REFERENCES `downloadable_link` (`link_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `DOWNLOADABLE_LINK_PRICE_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `downloadable_link_purchased`
  ADD CONSTRAINT `DL_LNK_PURCHASED_CSTR_ID_CSTR_ENTT_ENTT_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE SET NULL,
  ADD CONSTRAINT `DOWNLOADABLE_LINK_PURCHASED_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE SET NULL;

ALTER TABLE `downloadable_link_purchased_item`
  ADD CONSTRAINT `DL_LNK_PURCHASED_ITEM_ORDER_ITEM_ID_SALES_ORDER_ITEM_ITEM_ID` FOREIGN KEY (`order_item_id`) REFERENCES `sales_order_item` (`item_id`) ON DELETE SET NULL,
  ADD CONSTRAINT `DL_LNK_PURCHASED_ITEM_PURCHASED_ID_DL_LNK_PURCHASED_PURCHASED_ID` FOREIGN KEY (`purchased_id`) REFERENCES `downloadable_link_purchased` (`purchased_id`) ON DELETE CASCADE;

ALTER TABLE `downloadable_link_title`
  ADD CONSTRAINT `DOWNLOADABLE_LINK_TITLE_LINK_ID_DOWNLOADABLE_LINK_LINK_ID` FOREIGN KEY (`link_id`) REFERENCES `downloadable_link` (`link_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `DOWNLOADABLE_LINK_TITLE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `downloadable_sample`
  ADD CONSTRAINT `DOWNLOADABLE_SAMPLE_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `downloadable_sample_title`
  ADD CONSTRAINT `DL_SAMPLE_TTL_SAMPLE_ID_DL_SAMPLE_SAMPLE_ID` FOREIGN KEY (`sample_id`) REFERENCES `downloadable_sample` (`sample_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `DOWNLOADABLE_SAMPLE_TITLE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_attribute`
  ADD CONSTRAINT `EAV_ATTRIBUTE_ENTITY_TYPE_ID_EAV_ENTITY_TYPE_ENTITY_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE;

ALTER TABLE `eav_attribute_group`
  ADD CONSTRAINT `EAV_ATTR_GROUP_ATTR_SET_ID_EAV_ATTR_SET_ATTR_SET_ID` FOREIGN KEY (`attribute_set_id`) REFERENCES `eav_attribute_set` (`attribute_set_id`) ON DELETE CASCADE;

ALTER TABLE `eav_attribute_label`
  ADD CONSTRAINT `EAV_ATTRIBUTE_LABEL_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ATTRIBUTE_LABEL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_attribute_option`
  ADD CONSTRAINT `EAV_ATTRIBUTE_OPTION_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE;

ALTER TABLE `eav_attribute_option_swatch`
  ADD CONSTRAINT `EAV_ATTRIBUTE_OPTION_SWATCH_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ATTR_OPT_SWATCH_OPT_ID_EAV_ATTR_OPT_OPT_ID` FOREIGN KEY (`option_id`) REFERENCES `eav_attribute_option` (`option_id`) ON DELETE CASCADE;

ALTER TABLE `eav_attribute_option_value`
  ADD CONSTRAINT `EAV_ATTRIBUTE_OPTION_VALUE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ATTR_OPT_VAL_OPT_ID_EAV_ATTR_OPT_OPT_ID` FOREIGN KEY (`option_id`) REFERENCES `eav_attribute_option` (`option_id`) ON DELETE CASCADE;

ALTER TABLE `eav_attribute_set`
  ADD CONSTRAINT `EAV_ATTRIBUTE_SET_ENTITY_TYPE_ID_EAV_ENTITY_TYPE_ENTITY_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE;

ALTER TABLE `eav_entity`
  ADD CONSTRAINT `EAV_ENTITY_ENTITY_TYPE_ID_EAV_ENTITY_TYPE_ENTITY_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_entity_attribute`
  ADD CONSTRAINT `EAV_ENTITY_ATTRIBUTE_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTT_ATTR_ATTR_GROUP_ID_EAV_ATTR_GROUP_ATTR_GROUP_ID` FOREIGN KEY (`attribute_group_id`) REFERENCES `eav_attribute_group` (`attribute_group_id`) ON DELETE CASCADE;

ALTER TABLE `eav_entity_datetime`
  ADD CONSTRAINT `EAV_ENTITY_DATETIME_ENTITY_ID_EAV_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `eav_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_DATETIME_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTT_DTIME_ENTT_TYPE_ID_EAV_ENTT_TYPE_ENTT_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE;

ALTER TABLE `eav_entity_decimal`
  ADD CONSTRAINT `EAV_ENTITY_DECIMAL_ENTITY_ID_EAV_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `eav_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_DECIMAL_ENTITY_TYPE_ID_EAV_ENTITY_TYPE_ENTITY_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_DECIMAL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_entity_int`
  ADD CONSTRAINT `EAV_ENTITY_INT_ENTITY_ID_EAV_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `eav_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_INT_ENTITY_TYPE_ID_EAV_ENTITY_TYPE_ENTITY_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_INT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_entity_store`
  ADD CONSTRAINT `EAV_ENTITY_STORE_ENTITY_TYPE_ID_EAV_ENTITY_TYPE_ENTITY_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_entity_text`
  ADD CONSTRAINT `EAV_ENTITY_TEXT_ENTITY_ID_EAV_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `eav_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_TEXT_ENTITY_TYPE_ID_EAV_ENTITY_TYPE_ENTITY_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_TEXT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_entity_varchar`
  ADD CONSTRAINT `EAV_ENTITY_VARCHAR_ENTITY_ID_EAV_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `eav_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_VARCHAR_ENTITY_TYPE_ID_EAV_ENTITY_TYPE_ENTITY_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_ENTITY_VARCHAR_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_form_element`
  ADD CONSTRAINT `EAV_FORM_ELEMENT_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_FORM_ELEMENT_FIELDSET_ID_EAV_FORM_FIELDSET_FIELDSET_ID` FOREIGN KEY (`fieldset_id`) REFERENCES `eav_form_fieldset` (`fieldset_id`) ON DELETE SET NULL,
  ADD CONSTRAINT `EAV_FORM_ELEMENT_TYPE_ID_EAV_FORM_TYPE_TYPE_ID` FOREIGN KEY (`type_id`) REFERENCES `eav_form_type` (`type_id`) ON DELETE CASCADE;

ALTER TABLE `eav_form_fieldset`
  ADD CONSTRAINT `EAV_FORM_FIELDSET_TYPE_ID_EAV_FORM_TYPE_TYPE_ID` FOREIGN KEY (`type_id`) REFERENCES `eav_form_type` (`type_id`) ON DELETE CASCADE;

ALTER TABLE `eav_form_fieldset_label`
  ADD CONSTRAINT `EAV_FORM_FIELDSET_LABEL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_FORM_FSET_LBL_FSET_ID_EAV_FORM_FSET_FSET_ID` FOREIGN KEY (`fieldset_id`) REFERENCES `eav_form_fieldset` (`fieldset_id`) ON DELETE CASCADE;

ALTER TABLE `eav_form_type`
  ADD CONSTRAINT `EAV_FORM_TYPE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `eav_form_type_entity`
  ADD CONSTRAINT `EAV_FORM_TYPE_ENTITY_TYPE_ID_EAV_FORM_TYPE_TYPE_ID` FOREIGN KEY (`type_id`) REFERENCES `eav_form_type` (`type_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EAV_FORM_TYPE_ENTT_ENTT_TYPE_ID_EAV_ENTT_TYPE_ENTT_TYPE_ID` FOREIGN KEY (`entity_type_id`) REFERENCES `eav_entity_type` (`entity_type_id`) ON DELETE CASCADE;

ALTER TABLE `email_campaign`
  ADD CONSTRAINT `EMAIL_CAMPAIGN_STORE_ID_CORE/STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `email_catalog`
  ADD CONSTRAINT `EMAIL_CATALOG_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `email_contact`
  ADD CONSTRAINT `EMAIL_CONTACT_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `email_contact_consent`
  ADD CONSTRAINT `FK_17E9EA0C469163E550BC6B732AC49FDB` FOREIGN KEY (`email_contact_id`) REFERENCES `email_contact` (`email_contact_id`) ON DELETE CASCADE;

ALTER TABLE `email_coupon_attribute`
  ADD CONSTRAINT `EMAIL_COUPON_ATTRIBUTE_COUPON_ID_SALESRULE_COUPON_COUPON_ID` FOREIGN KEY (`salesrule_coupon_id`) REFERENCES `salesrule_coupon` (`coupon_id`) ON DELETE CASCADE;

ALTER TABLE `email_order`
  ADD CONSTRAINT `EMAIL_ORDER_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EMAIL_ORDER_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `email_sms_order_queue`
  ADD CONSTRAINT `EMAIL_SMS_ORDER_QUEUE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EMAIL_SMS_ORDER_QUEUE_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `email_wishlist`
  ADD CONSTRAINT `EMAIL_WISHLIST_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `EMAIL_WISHLIST_WISHLIST_ID_WISHLIST_WISHLIST_ID` FOREIGN KEY (`wishlist_id`) REFERENCES `wishlist` (`wishlist_id`) ON DELETE CASCADE;

ALTER TABLE `googleoptimizer_code`
  ADD CONSTRAINT `GOOGLEOPTIMIZER_CODE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `integration`
  ADD CONSTRAINT `INTEGRATION_CONSUMER_ID_OAUTH_CONSUMER_ENTITY_ID` FOREIGN KEY (`consumer_id`) REFERENCES `oauth_consumer` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `inventory_order_notification`
  ADD CONSTRAINT `INVENTORY_ORDER_NOTIFICATION_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `inventory_pickup_location_order`
  ADD CONSTRAINT `INVENTORY_PICKUP_LOCATION_ORDER_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `inventory_pickup_location_quote_address`
  ADD CONSTRAINT `INV_PICKUP_LOCATION_QUOTE_ADDR_ADDR_ID_QUOTE_ADDR_ADDR_ID` FOREIGN KEY (`address_id`) REFERENCES `quote_address` (`address_id`) ON DELETE CASCADE;

ALTER TABLE `inventory_source_carrier_link`
  ADD CONSTRAINT `INV_SOURCE_CARRIER_LNK_SOURCE_CODE_INV_SOURCE_SOURCE_CODE` FOREIGN KEY (`source_code`) REFERENCES `inventory_source` (`source_code`) ON DELETE CASCADE;

ALTER TABLE `inventory_source_item`
  ADD CONSTRAINT `INVENTORY_SOURCE_ITEM_SOURCE_CODE_INVENTORY_SOURCE_SOURCE_CODE` FOREIGN KEY (`source_code`) REFERENCES `inventory_source` (`source_code`) ON DELETE CASCADE;

ALTER TABLE `inventory_source_stock_link`
  ADD CONSTRAINT `INVENTORY_SOURCE_STOCK_LINK_STOCK_ID_INVENTORY_STOCK_STOCK_ID` FOREIGN KEY (`stock_id`) REFERENCES `inventory_stock` (`stock_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `INV_SOURCE_STOCK_LNK_SOURCE_CODE_INV_SOURCE_SOURCE_CODE` FOREIGN KEY (`source_code`) REFERENCES `inventory_source` (`source_code`) ON DELETE CASCADE;

ALTER TABLE `inventory_stock_sales_channel`
  ADD CONSTRAINT `INVENTORY_STOCK_SALES_CHANNEL_STOCK_ID_INVENTORY_STOCK_STOCK_ID` FOREIGN KEY (`stock_id`) REFERENCES `inventory_stock` (`stock_id`) ON DELETE CASCADE;

ALTER TABLE `klarna_payments_quote`
  ADD CONSTRAINT `KLARNA_PAYMENTS_QUOTE_QUOTE_ID_QUOTE_ENTITY_ID` FOREIGN KEY (`quote_id`) REFERENCES `quote` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `layout_link`
  ADD CONSTRAINT `LAYOUT_LINK_LAYOUT_UPDATE_ID_LAYOUT_UPDATE_LAYOUT_UPDATE_ID` FOREIGN KEY (`layout_update_id`) REFERENCES `layout_update` (`layout_update_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `LAYOUT_LINK_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `LAYOUT_LINK_THEME_ID_THEME_THEME_ID` FOREIGN KEY (`theme_id`) REFERENCES `theme` (`theme_id`) ON DELETE CASCADE;

ALTER TABLE `login_as_customer_assistance_allowed`
  ADD CONSTRAINT `LOGIN_AS_CSTR_ASSISTANCE_ALLOWED_CSTR_ID_CSTR_ENTT_ENTT_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `magefan_blog_category_store`
  ADD CONSTRAINT `MAGEFAN_BLOG_CATEGORY_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `MAGEFAN_BLOG_CTGR_STORE_CTGR_ID_MAGEFAN_BLOG_CTGR_CTGR_ID` FOREIGN KEY (`category_id`) REFERENCES `magefan_blog_category` (`category_id`) ON DELETE CASCADE;

ALTER TABLE `magefan_blog_comment`
  ADD CONSTRAINT `MAGEFAN_BLOG_COMMENT_POST_ID_MAGEFAN_BLOG_POST_POST_ID` FOREIGN KEY (`post_id`) REFERENCES `magefan_blog_post` (`post_id`) ON DELETE CASCADE;

ALTER TABLE `magefan_blog_post_category`
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_CATEGORY_POST_ID_MAGEFAN_BLOG_POST_POST_ID` FOREIGN KEY (`post_id`) REFERENCES `magefan_blog_post` (`post_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_CTGR_CTGR_ID_MAGEFAN_BLOG_CTGR_CTGR_ID` FOREIGN KEY (`category_id`) REFERENCES `magefan_blog_category` (`category_id`) ON DELETE CASCADE;

ALTER TABLE `magefan_blog_post_relatedpost`
  ADD CONSTRAINT `FK_9F26E983FE1D7D7063B61D3F3C8D1104` FOREIGN KEY (`post_id`) REFERENCES `magefan_blog_post` (`post_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_RELATEDPRD1_POST_ID_MAGEFAN_BLOG_POST_POST_ID` FOREIGN KEY (`post_id`) REFERENCES `magefan_blog_post` (`post_id`) ON DELETE CASCADE;

ALTER TABLE `magefan_blog_post_relatedproduct`
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_RELATEDPRD_POST_ID_MAGEFAN_BLOG_POST_POST_ID` FOREIGN KEY (`post_id`) REFERENCES `magefan_blog_post` (`post_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_RELATEDPRD_RELATED_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`related_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `magefan_blog_post_store`
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_STORE_POST_ID_MAGEFAN_BLOG_POST_POST_ID` FOREIGN KEY (`post_id`) REFERENCES `magefan_blog_post` (`post_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `magefan_blog_post_tag`
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_TAG_POST_ID_MAGEFAN_BLOG_POST_POST_ID` FOREIGN KEY (`post_id`) REFERENCES `magefan_blog_post` (`post_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `MAGEFAN_BLOG_POST_TAG_TAG_ID_MAGEFAN_BLOG_TAG_TAG_ID` FOREIGN KEY (`tag_id`) REFERENCES `magefan_blog_tag` (`tag_id`) ON DELETE CASCADE;

ALTER TABLE `magefan_blog_tag_store`
  ADD CONSTRAINT `MAGEFAN_BLOG_TAG_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `MAGEFAN_BLOG_TAG_STORE_TAG_ID_MAGEFAN_BLOG_TAG_TAG_ID` FOREIGN KEY (`tag_id`) REFERENCES `magefan_blog_tag` (`tag_id`) ON DELETE CASCADE;

ALTER TABLE `magento_acknowledged_bulk`
  ADD CONSTRAINT `MAGENTO_ACKNOWLEDGED_BULK_BULK_UUID_MAGENTO_BULK_UUID` FOREIGN KEY (`bulk_uuid`) REFERENCES `magento_bulk` (`uuid`) ON DELETE CASCADE;

ALTER TABLE `magento_operation`
  ADD CONSTRAINT `MAGENTO_OPERATION_BULK_UUID_MAGENTO_BULK_UUID` FOREIGN KEY (`bulk_uuid`) REFERENCES `magento_bulk` (`uuid`) ON DELETE CASCADE;

ALTER TABLE `media_gallery_asset_keyword`
  ADD CONSTRAINT `MEDIA_GALLERY_ASSET_KEYWORD_ASSET_ID_MEDIA_GALLERY_ASSET_ID` FOREIGN KEY (`asset_id`) REFERENCES `media_gallery_asset` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `MEDIA_GALLERY_ASSET_KEYWORD_KEYWORD_ID_MEDIA_GALLERY_KEYWORD_ID` FOREIGN KEY (`keyword_id`) REFERENCES `media_gallery_keyword` (`id`) ON DELETE CASCADE;

ALTER TABLE `newsletter_problem`
  ADD CONSTRAINT `NEWSLETTER_PROBLEM_QUEUE_ID_NEWSLETTER_QUEUE_QUEUE_ID` FOREIGN KEY (`queue_id`) REFERENCES `newsletter_queue` (`queue_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `NLTTR_PROBLEM_SUBSCRIBER_ID_NLTTR_SUBSCRIBER_SUBSCRIBER_ID` FOREIGN KEY (`subscriber_id`) REFERENCES `newsletter_subscriber` (`subscriber_id`) ON DELETE CASCADE;

ALTER TABLE `newsletter_queue`
  ADD CONSTRAINT `NEWSLETTER_QUEUE_TEMPLATE_ID_NEWSLETTER_TEMPLATE_TEMPLATE_ID` FOREIGN KEY (`template_id`) REFERENCES `newsletter_template` (`template_id`) ON DELETE CASCADE;

ALTER TABLE `newsletter_queue_link`
  ADD CONSTRAINT `NEWSLETTER_QUEUE_LINK_QUEUE_ID_NEWSLETTER_QUEUE_QUEUE_ID` FOREIGN KEY (`queue_id`) REFERENCES `newsletter_queue` (`queue_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `NLTTR_QUEUE_LNK_SUBSCRIBER_ID_NLTTR_SUBSCRIBER_SUBSCRIBER_ID` FOREIGN KEY (`subscriber_id`) REFERENCES `newsletter_subscriber` (`subscriber_id`) ON DELETE CASCADE;

ALTER TABLE `newsletter_queue_store_link`
  ADD CONSTRAINT `NEWSLETTER_QUEUE_STORE_LINK_QUEUE_ID_NEWSLETTER_QUEUE_QUEUE_ID` FOREIGN KEY (`queue_id`) REFERENCES `newsletter_queue` (`queue_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `NEWSLETTER_QUEUE_STORE_LINK_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `newsletter_subscriber`
  ADD CONSTRAINT `NEWSLETTER_SUBSCRIBER_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `oauth_nonce`
  ADD CONSTRAINT `OAUTH_NONCE_CONSUMER_ID_OAUTH_CONSUMER_ENTITY_ID` FOREIGN KEY (`consumer_id`) REFERENCES `oauth_consumer` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `oauth_token`
  ADD CONSTRAINT `OAUTH_TOKEN_ADMIN_ID_ADMIN_USER_USER_ID` FOREIGN KEY (`admin_id`) REFERENCES `admin_user` (`user_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `OAUTH_TOKEN_CONSUMER_ID_OAUTH_CONSUMER_ENTITY_ID` FOREIGN KEY (`consumer_id`) REFERENCES `oauth_consumer` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `OAUTH_TOKEN_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `paypal_billing_agreement`
  ADD CONSTRAINT `PAYPAL_BILLING_AGREEMENT_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PAYPAL_BILLING_AGREEMENT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `paypal_billing_agreement_order`
  ADD CONSTRAINT `PAYPAL_BILLING_AGREEMENT_ORDER_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PAYPAL_BILLING_AGRT_ORDER_AGRT_ID_PAYPAL_BILLING_AGRT_AGRT_ID` FOREIGN KEY (`agreement_id`) REFERENCES `paypal_billing_agreement` (`agreement_id`) ON DELETE CASCADE;

ALTER TABLE `paypal_cert`
  ADD CONSTRAINT `PAYPAL_CERT_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `paypal_settlement_report_row`
  ADD CONSTRAINT `FK_E183E488F593E0DE10C6EBFFEBAC9B55` FOREIGN KEY (`report_id`) REFERENCES `paypal_settlement_report` (`report_id`) ON DELETE CASCADE;

ALTER TABLE `persistent_session`
  ADD CONSTRAINT `PERSISTENT_SESSION_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PERSISTENT_SESSION_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `product_alert_price`
  ADD CONSTRAINT `PRODUCT_ALERT_PRICE_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PRODUCT_ALERT_PRICE_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PRODUCT_ALERT_PRICE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PRODUCT_ALERT_PRICE_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `product_alert_stock`
  ADD CONSTRAINT `PRODUCT_ALERT_STOCK_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PRODUCT_ALERT_STOCK_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PRODUCT_ALERT_STOCK_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `PRODUCT_ALERT_STOCK_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `queue_message_status`
  ADD CONSTRAINT `QUEUE_MESSAGE_STATUS_MESSAGE_ID_QUEUE_MESSAGE_ID` FOREIGN KEY (`message_id`) REFERENCES `queue_message` (`id`) ON DELETE CASCADE,
  ADD CONSTRAINT `QUEUE_MESSAGE_STATUS_QUEUE_ID_QUEUE_ID` FOREIGN KEY (`queue_id`) REFERENCES `queue` (`id`) ON DELETE CASCADE;

ALTER TABLE `quote`
  ADD CONSTRAINT `QUOTE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `quote_address`
  ADD CONSTRAINT `QUOTE_ADDRESS_QUOTE_ID_QUOTE_ENTITY_ID` FOREIGN KEY (`quote_id`) REFERENCES `quote` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `quote_address_item`
  ADD CONSTRAINT `QUOTE_ADDRESS_ITEM_QUOTE_ADDRESS_ID_QUOTE_ADDRESS_ADDRESS_ID` FOREIGN KEY (`quote_address_id`) REFERENCES `quote_address` (`address_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `QUOTE_ADDRESS_ITEM_QUOTE_ITEM_ID_QUOTE_ITEM_ITEM_ID` FOREIGN KEY (`quote_item_id`) REFERENCES `quote_item` (`item_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `QUOTE_ADDR_ITEM_PARENT_ITEM_ID_QUOTE_ADDR_ITEM_ADDR_ITEM_ID` FOREIGN KEY (`parent_item_id`) REFERENCES `quote_address_item` (`address_item_id`) ON DELETE CASCADE;

ALTER TABLE `quote_id_mask`
  ADD CONSTRAINT `QUOTE_ID_MASK_QUOTE_ID_QUOTE_ENTITY_ID` FOREIGN KEY (`quote_id`) REFERENCES `quote` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `quote_item`
  ADD CONSTRAINT `QUOTE_ITEM_PARENT_ITEM_ID_QUOTE_ITEM_ITEM_ID` FOREIGN KEY (`parent_item_id`) REFERENCES `quote_item` (`item_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `QUOTE_ITEM_QUOTE_ID_QUOTE_ENTITY_ID` FOREIGN KEY (`quote_id`) REFERENCES `quote` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `QUOTE_ITEM_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `quote_item_option`
  ADD CONSTRAINT `QUOTE_ITEM_OPTION_ITEM_ID_QUOTE_ITEM_ITEM_ID` FOREIGN KEY (`item_id`) REFERENCES `quote_item` (`item_id`) ON DELETE CASCADE;

ALTER TABLE `quote_payment`
  ADD CONSTRAINT `QUOTE_PAYMENT_QUOTE_ID_QUOTE_ENTITY_ID` FOREIGN KEY (`quote_id`) REFERENCES `quote` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `quote_shipping_rate`
  ADD CONSTRAINT `QUOTE_SHIPPING_RATE_ADDRESS_ID_QUOTE_ADDRESS_ADDRESS_ID` FOREIGN KEY (`address_id`) REFERENCES `quote_address` (`address_id`) ON DELETE CASCADE;

ALTER TABLE `rating`
  ADD CONSTRAINT `RATING_ENTITY_ID_RATING_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `rating_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `rating_option`
  ADD CONSTRAINT `RATING_OPTION_RATING_ID_RATING_RATING_ID` FOREIGN KEY (`rating_id`) REFERENCES `rating` (`rating_id`) ON DELETE CASCADE;

ALTER TABLE `rating_option_vote`
  ADD CONSTRAINT `RATING_OPTION_VOTE_OPTION_ID_RATING_OPTION_OPTION_ID` FOREIGN KEY (`option_id`) REFERENCES `rating_option` (`option_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `RATING_OPTION_VOTE_REVIEW_ID_REVIEW_REVIEW_ID` FOREIGN KEY (`review_id`) REFERENCES `review` (`review_id`) ON DELETE CASCADE;

ALTER TABLE `rating_option_vote_aggregated`
  ADD CONSTRAINT `RATING_OPTION_VOTE_AGGREGATED_RATING_ID_RATING_RATING_ID` FOREIGN KEY (`rating_id`) REFERENCES `rating` (`rating_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `RATING_OPTION_VOTE_AGGREGATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `rating_store`
  ADD CONSTRAINT `RATING_STORE_RATING_ID_RATING_RATING_ID` FOREIGN KEY (`rating_id`) REFERENCES `rating` (`rating_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `RATING_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `rating_title`
  ADD CONSTRAINT `RATING_TITLE_RATING_ID_RATING_RATING_ID` FOREIGN KEY (`rating_id`) REFERENCES `rating` (`rating_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `RATING_TITLE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `release_notification_viewer_log`
  ADD CONSTRAINT `RELEASE_NOTIFICATION_VIEWER_LOG_VIEWER_ID_ADMIN_USER_USER_ID` FOREIGN KEY (`viewer_id`) REFERENCES `admin_user` (`user_id`) ON DELETE CASCADE;

ALTER TABLE `report_compared_product_index`
  ADD CONSTRAINT `REPORT_CMPD_PRD_IDX_CSTR_ID_CSTR_ENTT_ENTT_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REPORT_CMPD_PRD_IDX_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REPORT_COMPARED_PRODUCT_INDEX_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `report_event`
  ADD CONSTRAINT `REPORT_EVENT_EVENT_TYPE_ID_REPORT_EVENT_TYPES_EVENT_TYPE_ID` FOREIGN KEY (`event_type_id`) REFERENCES `report_event_types` (`event_type_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REPORT_EVENT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `report_viewed_product_aggregated_daily`
  ADD CONSTRAINT `REPORT_VIEWED_PRD_AGGRED_DAILY_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REPORT_VIEWED_PRODUCT_AGGREGATED_DAILY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `report_viewed_product_aggregated_monthly`
  ADD CONSTRAINT `REPORT_VIEWED_PRD_AGGRED_MONTHLY_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REPORT_VIEWED_PRODUCT_AGGREGATED_MONTHLY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `report_viewed_product_aggregated_yearly`
  ADD CONSTRAINT `REPORT_VIEWED_PRD_AGGRED_YEARLY_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REPORT_VIEWED_PRODUCT_AGGREGATED_YEARLY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `report_viewed_product_index`
  ADD CONSTRAINT `REPORT_VIEWED_PRD_IDX_CSTR_ID_CSTR_ENTT_ENTT_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REPORT_VIEWED_PRD_IDX_PRD_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REPORT_VIEWED_PRODUCT_INDEX_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `review`
  ADD CONSTRAINT `REVIEW_ENTITY_ID_REVIEW_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `review_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REVIEW_STATUS_ID_REVIEW_STATUS_STATUS_ID` FOREIGN KEY (`status_id`) REFERENCES `review_status` (`status_id`) ON DELETE NO ACTION;

ALTER TABLE `review_detail`
  ADD CONSTRAINT `REVIEW_DETAIL_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE SET NULL,
  ADD CONSTRAINT `REVIEW_DETAIL_REVIEW_ID_REVIEW_REVIEW_ID` FOREIGN KEY (`review_id`) REFERENCES `review` (`review_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REVIEW_DETAIL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `review_entity_summary`
  ADD CONSTRAINT `REVIEW_ENTITY_SUMMARY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `review_store`
  ADD CONSTRAINT `REVIEW_STORE_REVIEW_ID_REVIEW_REVIEW_ID` FOREIGN KEY (`review_id`) REFERENCES `review` (`review_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `REVIEW_STORE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `sales_bestsellers_aggregated_daily`
  ADD CONSTRAINT `SALES_BESTSELLERS_AGGREGATED_DAILY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `sales_bestsellers_aggregated_monthly`
  ADD CONSTRAINT `SALES_BESTSELLERS_AGGREGATED_MONTHLY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `sales_bestsellers_aggregated_yearly`
  ADD CONSTRAINT `SALES_BESTSELLERS_AGGREGATED_YEARLY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `sales_creditmemo`
  ADD CONSTRAINT `SALES_CREDITMEMO_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_CREDITMEMO_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_creditmemo_comment`
  ADD CONSTRAINT `SALES_CREDITMEMO_COMMENT_PARENT_ID_SALES_CREDITMEMO_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_creditmemo` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_creditmemo_item`
  ADD CONSTRAINT `SALES_CREDITMEMO_ITEM_PARENT_ID_SALES_CREDITMEMO_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_creditmemo` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_invoice`
  ADD CONSTRAINT `SALES_INVOICE_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_INVOICE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_invoice_comment`
  ADD CONSTRAINT `SALES_INVOICE_COMMENT_PARENT_ID_SALES_INVOICE_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_invoice` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_invoice_item`
  ADD CONSTRAINT `SALES_INVOICE_ITEM_PARENT_ID_SALES_INVOICE_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_invoice` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_invoiced_aggregated`
  ADD CONSTRAINT `SALES_INVOICED_AGGREGATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_invoiced_aggregated_order`
  ADD CONSTRAINT `SALES_INVOICED_AGGREGATED_ORDER_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_order`
  ADD CONSTRAINT `SALES_ORDER_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE SET NULL,
  ADD CONSTRAINT `SALES_ORDER_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_order_address`
  ADD CONSTRAINT `SALES_ORDER_ADDRESS_PARENT_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_order_aggregated_created`
  ADD CONSTRAINT `SALES_ORDER_AGGREGATED_CREATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_order_aggregated_updated`
  ADD CONSTRAINT `SALES_ORDER_AGGREGATED_UPDATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_order_item`
  ADD CONSTRAINT `SALES_ORDER_ITEM_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_ORDER_ITEM_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_order_payment`
  ADD CONSTRAINT `SALES_ORDER_PAYMENT_PARENT_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_order_status_history`
  ADD CONSTRAINT `SALES_ORDER_STATUS_HISTORY_PARENT_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_order_status_label`
  ADD CONSTRAINT `SALES_ORDER_STATUS_LABEL_STATUS_SALES_ORDER_STATUS_STATUS` FOREIGN KEY (`status`) REFERENCES `sales_order_status` (`status`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_ORDER_STATUS_LABEL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `sales_order_status_state`
  ADD CONSTRAINT `SALES_ORDER_STATUS_STATE_STATUS_SALES_ORDER_STATUS_STATUS` FOREIGN KEY (`status`) REFERENCES `sales_order_status` (`status`) ON DELETE CASCADE;

ALTER TABLE `sales_order_tax_item`
  ADD CONSTRAINT `SALES_ORDER_TAX_ITEM_ASSOCIATED_ITEM_ID_SALES_ORDER_ITEM_ITEM_ID` FOREIGN KEY (`associated_item_id`) REFERENCES `sales_order_item` (`item_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_ORDER_TAX_ITEM_ITEM_ID_SALES_ORDER_ITEM_ITEM_ID` FOREIGN KEY (`item_id`) REFERENCES `sales_order_item` (`item_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_ORDER_TAX_ITEM_TAX_ID_SALES_ORDER_TAX_TAX_ID` FOREIGN KEY (`tax_id`) REFERENCES `sales_order_tax` (`tax_id`) ON DELETE CASCADE;

ALTER TABLE `sales_payment_transaction`
  ADD CONSTRAINT `FK_B99FF1A06402D725EBDB0F3A7ECD47A2` FOREIGN KEY (`parent_id`) REFERENCES `sales_payment_transaction` (`transaction_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_PAYMENT_TRANSACTION_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_PAYMENT_TRANSACTION_PAYMENT_ID_SALES_ORDER_PAYMENT_ENTT_ID` FOREIGN KEY (`payment_id`) REFERENCES `sales_order_payment` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_refunded_aggregated`
  ADD CONSTRAINT `SALES_REFUNDED_AGGREGATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_refunded_aggregated_order`
  ADD CONSTRAINT `SALES_REFUNDED_AGGREGATED_ORDER_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_sequence_profile`
  ADD CONSTRAINT `SALES_SEQUENCE_PROFILE_META_ID_SALES_SEQUENCE_META_META_ID` FOREIGN KEY (`meta_id`) REFERENCES `sales_sequence_meta` (`meta_id`) ON DELETE CASCADE;

ALTER TABLE `sales_shipment`
  ADD CONSTRAINT `SALES_SHIPMENT_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALES_SHIPMENT_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_shipment_comment`
  ADD CONSTRAINT `SALES_SHIPMENT_COMMENT_PARENT_ID_SALES_SHIPMENT_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_shipment` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_shipment_item`
  ADD CONSTRAINT `SALES_SHIPMENT_ITEM_PARENT_ID_SALES_SHIPMENT_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_shipment` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_shipment_track`
  ADD CONSTRAINT `SALES_SHIPMENT_TRACK_PARENT_ID_SALES_SHIPMENT_ENTITY_ID` FOREIGN KEY (`parent_id`) REFERENCES `sales_shipment` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `sales_shipping_aggregated`
  ADD CONSTRAINT `SALES_SHIPPING_AGGREGATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `sales_shipping_aggregated_order`
  ADD CONSTRAINT `SALES_SHIPPING_AGGREGATED_ORDER_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL;

ALTER TABLE `salesrule_coupon`
  ADD CONSTRAINT `SALESRULE_COUPON_RULE_ID_SALESRULE_RULE_ID` FOREIGN KEY (`rule_id`) REFERENCES `salesrule` (`rule_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_coupon_aggregated`
  ADD CONSTRAINT `SALESRULE_COUPON_AGGREGATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_coupon_aggregated_order`
  ADD CONSTRAINT `SALESRULE_COUPON_AGGREGATED_ORDER_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_coupon_aggregated_updated`
  ADD CONSTRAINT `SALESRULE_COUPON_AGGREGATED_UPDATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_coupon_usage`
  ADD CONSTRAINT `SALESRULE_COUPON_USAGE_COUPON_ID_SALESRULE_COUPON_COUPON_ID` FOREIGN KEY (`coupon_id`) REFERENCES `salesrule_coupon` (`coupon_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALESRULE_COUPON_USAGE_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_customer`
  ADD CONSTRAINT `SALESRULE_CUSTOMER_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALESRULE_CUSTOMER_RULE_ID_SALESRULE_RULE_ID` FOREIGN KEY (`rule_id`) REFERENCES `salesrule` (`rule_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_customer_group`
  ADD CONSTRAINT `SALESRULE_CSTR_GROUP_CSTR_GROUP_ID_CSTR_GROUP_CSTR_GROUP_ID` FOREIGN KEY (`customer_group_id`) REFERENCES `customer_group` (`customer_group_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALESRULE_CUSTOMER_GROUP_RULE_ID_SALESRULE_RULE_ID` FOREIGN KEY (`rule_id`) REFERENCES `salesrule` (`rule_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_label`
  ADD CONSTRAINT `SALESRULE_LABEL_RULE_ID_SALESRULE_RULE_ID` FOREIGN KEY (`rule_id`) REFERENCES `salesrule` (`rule_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALESRULE_LABEL_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_product_attribute`
  ADD CONSTRAINT `SALESRULE_PRD_ATTR_ATTR_ID_EAV_ATTR_ATTR_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALESRULE_PRD_ATTR_CSTR_GROUP_ID_CSTR_GROUP_CSTR_GROUP_ID` FOREIGN KEY (`customer_group_id`) REFERENCES `customer_group` (`customer_group_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALESRULE_PRODUCT_ATTRIBUTE_RULE_ID_SALESRULE_RULE_ID` FOREIGN KEY (`rule_id`) REFERENCES `salesrule` (`rule_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALESRULE_PRODUCT_ATTRIBUTE_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `salesrule_website`
  ADD CONSTRAINT `SALESRULE_WEBSITE_RULE_ID_SALESRULE_RULE_ID` FOREIGN KEY (`rule_id`) REFERENCES `salesrule` (`rule_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SALESRULE_WEBSITE_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `search_query`
  ADD CONSTRAINT `SEARCH_QUERY_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `search_synonyms`
  ADD CONSTRAINT `SEARCH_SYNONYMS_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `SEARCH_SYNONYMS_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `signifyd_case`
  ADD CONSTRAINT `SIGNIFYD_CASE_ORDER_ID_SALES_ORDER_ENTITY_ID` FOREIGN KEY (`order_id`) REFERENCES `sales_order` (`entity_id`) ON DELETE SET NULL;

ALTER TABLE `sitemap`
  ADD CONSTRAINT `SITEMAP_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `store`
  ADD CONSTRAINT `STORE_GROUP_ID_STORE_GROUP_GROUP_ID` FOREIGN KEY (`group_id`) REFERENCES `store_group` (`group_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `STORE_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `store_group`
  ADD CONSTRAINT `STORE_GROUP_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `tax_calculation`
  ADD CONSTRAINT `TAX_CALCULATION_CUSTOMER_TAX_CLASS_ID_TAX_CLASS_CLASS_ID` FOREIGN KEY (`customer_tax_class_id`) REFERENCES `tax_class` (`class_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `TAX_CALCULATION_PRODUCT_TAX_CLASS_ID_TAX_CLASS_CLASS_ID` FOREIGN KEY (`product_tax_class_id`) REFERENCES `tax_class` (`class_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `TAX_CALC_TAX_CALC_RATE_ID_TAX_CALC_RATE_TAX_CALC_RATE_ID` FOREIGN KEY (`tax_calculation_rate_id`) REFERENCES `tax_calculation_rate` (`tax_calculation_rate_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `TAX_CALC_TAX_CALC_RULE_ID_TAX_CALC_RULE_TAX_CALC_RULE_ID` FOREIGN KEY (`tax_calculation_rule_id`) REFERENCES `tax_calculation_rule` (`tax_calculation_rule_id`) ON DELETE CASCADE;

ALTER TABLE `tax_calculation_rate_title`
  ADD CONSTRAINT `FK_37FB965F786AD5897BB3AE90470C42AB` FOREIGN KEY (`tax_calculation_rate_id`) REFERENCES `tax_calculation_rate` (`tax_calculation_rate_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `TAX_CALCULATION_RATE_TITLE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `tax_order_aggregated_created`
  ADD CONSTRAINT `TAX_ORDER_AGGREGATED_CREATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `tax_order_aggregated_updated`
  ADD CONSTRAINT `TAX_ORDER_AGGREGATED_UPDATED_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `theme_file`
  ADD CONSTRAINT `THEME_FILE_THEME_ID_THEME_THEME_ID` FOREIGN KEY (`theme_id`) REFERENCES `theme` (`theme_id`) ON DELETE CASCADE;

ALTER TABLE `translation`
  ADD CONSTRAINT `TRANSLATION_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE;

ALTER TABLE `ui_bookmark`
  ADD CONSTRAINT `UI_BOOKMARK_USER_ID_ADMIN_USER_USER_ID` FOREIGN KEY (`user_id`) REFERENCES `admin_user` (`user_id`) ON DELETE CASCADE;

ALTER TABLE `variable_value`
  ADD CONSTRAINT `VARIABLE_VALUE_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `VARIABLE_VALUE_VARIABLE_ID_VARIABLE_VARIABLE_ID` FOREIGN KEY (`variable_id`) REFERENCES `variable` (`variable_id`) ON DELETE CASCADE;

ALTER TABLE `vault_payment_token`
  ADD CONSTRAINT `VAULT_PAYMENT_TOKEN_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `vault_payment_token_order_payment_link`
  ADD CONSTRAINT `FK_4ED894655446D385894580BECA993862` FOREIGN KEY (`payment_token_id`) REFERENCES `vault_payment_token` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `FK_CF37B9D854256534BE23C818F6291CA2` FOREIGN KEY (`order_payment_id`) REFERENCES `sales_order_payment` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `weee_tax`
  ADD CONSTRAINT `WEEE_TAX_ATTRIBUTE_ID_EAV_ATTRIBUTE_ATTRIBUTE_ID` FOREIGN KEY (`attribute_id`) REFERENCES `eav_attribute` (`attribute_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `WEEE_TAX_COUNTRY_DIRECTORY_COUNTRY_COUNTRY_ID` FOREIGN KEY (`country`) REFERENCES `directory_country` (`country_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `WEEE_TAX_ENTITY_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `WEEE_TAX_WEBSITE_ID_STORE_WEBSITE_WEBSITE_ID` FOREIGN KEY (`website_id`) REFERENCES `store_website` (`website_id`) ON DELETE CASCADE;

ALTER TABLE `widget_instance`
  ADD CONSTRAINT `WIDGET_INSTANCE_THEME_ID_THEME_THEME_ID` FOREIGN KEY (`theme_id`) REFERENCES `theme` (`theme_id`) ON DELETE CASCADE;

ALTER TABLE `widget_instance_page`
  ADD CONSTRAINT `WIDGET_INSTANCE_PAGE_INSTANCE_ID_WIDGET_INSTANCE_INSTANCE_ID` FOREIGN KEY (`instance_id`) REFERENCES `widget_instance` (`instance_id`) ON DELETE CASCADE;

ALTER TABLE `widget_instance_page_layout`
  ADD CONSTRAINT `WIDGET_INSTANCE_PAGE_LAYOUT_PAGE_ID_WIDGET_INSTANCE_PAGE_PAGE_ID` FOREIGN KEY (`page_id`) REFERENCES `widget_instance_page` (`page_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `WIDGET_INSTANCE_PAGE_LYT_LYT_UPDATE_ID_LYT_UPDATE_LYT_UPDATE_ID` FOREIGN KEY (`layout_update_id`) REFERENCES `layout_update` (`layout_update_id`) ON DELETE CASCADE;

ALTER TABLE `wishlist`
  ADD CONSTRAINT `WISHLIST_CUSTOMER_ID_CUSTOMER_ENTITY_ENTITY_ID` FOREIGN KEY (`customer_id`) REFERENCES `customer_entity` (`entity_id`) ON DELETE CASCADE;

ALTER TABLE `wishlist_item`
  ADD CONSTRAINT `WISHLIST_ITEM_PRODUCT_ID_CATALOG_PRODUCT_ENTITY_ENTITY_ID` FOREIGN KEY (`product_id`) REFERENCES `catalog_product_entity` (`entity_id`) ON DELETE CASCADE,
  ADD CONSTRAINT `WISHLIST_ITEM_STORE_ID_STORE_STORE_ID` FOREIGN KEY (`store_id`) REFERENCES `store` (`store_id`) ON DELETE SET NULL,
  ADD CONSTRAINT `WISHLIST_ITEM_WISHLIST_ID_WISHLIST_WISHLIST_ID` FOREIGN KEY (`wishlist_id`) REFERENCES `wishlist` (`wishlist_id`) ON DELETE CASCADE;

ALTER TABLE `wishlist_item_option`
  ADD CONSTRAINT `FK_A014B30B04B72DD0EAB3EECD779728D6` FOREIGN KEY (`wishlist_item_id`) REFERENCES `wishlist_item` (`wishlist_item_id`) ON DELETE CASCADE;

--
-- Triggers structure for table `catalog_category_entity`
--
DROP TRIGGER IF EXISTS trg_catalog_category_entity_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_entity_after_insert AFTER INSERT ON catalog_category_entity FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_category_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_category_entity_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_entity_after_update AFTER UPDATE ON catalog_category_entity FOR EACH ROW
BEGIN
IF (NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`attribute_set_id` <=> OLD.`attribute_set_id`) OR NOT(NEW.`parent_id` <=> OLD.`parent_id`) OR NOT(NEW.`created_at` <=> OLD.`created_at`) OR NOT(NEW.`path` <=> OLD.`path`) OR NOT(NEW.`position` <=> OLD.`position`) OR NOT(NEW.`level` <=> OLD.`level`) OR NOT(NEW.`children_count` <=> OLD.`children_count`)) THEN INSERT IGNORE INTO `catalog_category_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_category_entity_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_entity_after_delete AFTER DELETE ON catalog_category_entity FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_category_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_category_entity_int`
--
DROP TRIGGER IF EXISTS trg_catalog_category_entity_int_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_entity_int_after_insert AFTER INSERT ON catalog_category_entity_int FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_category_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_category_entity_int_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_entity_int_after_update AFTER UPDATE ON catalog_category_entity_int FOR EACH ROW
BEGIN
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalog_category_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_category_entity_int_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_entity_int_after_delete AFTER DELETE ON catalog_category_entity_int FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_category_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_category_product`
--
DROP TRIGGER IF EXISTS trg_catalog_category_product_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_product_after_insert AFTER INSERT ON catalog_category_product FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_category_product_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_product_after_update AFTER UPDATE ON catalog_category_product FOR EACH ROW
BEGIN
IF (NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`category_id` <=> OLD.`category_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`position` <=> OLD.`position`)) THEN INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`category_id` <=> OLD.`category_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`position` <=> OLD.`position`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`category_id` <=> OLD.`category_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`position` <=> OLD.`position`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_category_product_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_category_product_after_delete AFTER DELETE ON catalog_category_product FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`product_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_bundle_selection`
--
DROP TRIGGER IF EXISTS trg_catalog_product_bundle_selection_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_bundle_selection_after_insert AFTER INSERT ON catalog_product_bundle_selection FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`parent_product_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_bundle_selection_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_bundle_selection_after_update AFTER UPDATE ON catalog_product_bundle_selection FOR EACH ROW
BEGIN
IF (NOT(NEW.`selection_id` <=> OLD.`selection_id`) OR NOT(NEW.`option_id` <=> OLD.`option_id`) OR NOT(NEW.`parent_product_id` <=> OLD.`parent_product_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`position` <=> OLD.`position`) OR NOT(NEW.`is_default` <=> OLD.`is_default`) OR NOT(NEW.`selection_price_type` <=> OLD.`selection_price_type`) OR NOT(NEW.`selection_price_value` <=> OLD.`selection_price_value`) OR NOT(NEW.`selection_qty` <=> OLD.`selection_qty`) OR NOT(NEW.`selection_can_change_qty` <=> OLD.`selection_can_change_qty`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`parent_product_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_bundle_selection_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_bundle_selection_after_delete AFTER DELETE ON catalog_product_bundle_selection FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`parent_product_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_entity`
--
DROP TRIGGER IF EXISTS trg_catalog_product_entity_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_after_insert AFTER INSERT ON catalog_product_entity FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_after_update AFTER UPDATE ON catalog_product_entity FOR EACH ROW
BEGIN
IF (NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`attribute_set_id` <=> OLD.`attribute_set_id`) OR NOT(NEW.`type_id` <=> OLD.`type_id`) OR NOT(NEW.`sku` <=> OLD.`sku`) OR NOT(NEW.`has_options` <=> OLD.`has_options`) OR NOT(NEW.`required_options` <=> OLD.`required_options`) OR NOT(NEW.`created_at` <=> OLD.`created_at`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`attribute_set_id` <=> OLD.`attribute_set_id`) OR NOT(NEW.`type_id` <=> OLD.`type_id`) OR NOT(NEW.`sku` <=> OLD.`sku`) OR NOT(NEW.`has_options` <=> OLD.`has_options`) OR NOT(NEW.`required_options` <=> OLD.`required_options`) OR NOT(NEW.`created_at` <=> OLD.`created_at`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`attribute_set_id` <=> OLD.`attribute_set_id`) OR NOT(NEW.`type_id` <=> OLD.`type_id`) OR NOT(NEW.`sku` <=> OLD.`sku`) OR NOT(NEW.`has_options` <=> OLD.`has_options`) OR NOT(NEW.`required_options` <=> OLD.`required_options`) OR NOT(NEW.`created_at` <=> OLD.`created_at`)) THEN INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_after_delete AFTER DELETE ON catalog_product_entity FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_entity_datetime`
--
DROP TRIGGER IF EXISTS trg_catalog_product_entity_datetime_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_datetime_after_insert AFTER INSERT ON catalog_product_entity_datetime FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_datetime_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_datetime_after_update AFTER UPDATE ON catalog_product_entity_datetime FOR EACH ROW
BEGIN
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_datetime_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_datetime_after_delete AFTER DELETE ON catalog_product_entity_datetime FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_entity_decimal`
--
DROP TRIGGER IF EXISTS trg_catalog_product_entity_decimal_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_decimal_after_insert AFTER INSERT ON catalog_product_entity_decimal FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_decimal_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_decimal_after_update AFTER UPDATE ON catalog_product_entity_decimal FOR EACH ROW
BEGIN
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_decimal_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_decimal_after_delete AFTER DELETE ON catalog_product_entity_decimal FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_entity_int`
--
DROP TRIGGER IF EXISTS trg_catalog_product_entity_int_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_int_after_insert AFTER INSERT ON catalog_product_entity_int FOR EACH ROW
BEGIN
INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_int_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_int_after_update AFTER UPDATE ON catalog_product_entity_int FOR EACH ROW
BEGIN
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_int_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_int_after_delete AFTER DELETE ON catalog_product_entity_int FOR EACH ROW
BEGIN
INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_entity_text`
--
DROP TRIGGER IF EXISTS trg_catalog_product_entity_text_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_text_after_insert AFTER INSERT ON catalog_product_entity_text FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_text_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_text_after_update AFTER UPDATE ON catalog_product_entity_text FOR EACH ROW
BEGIN
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_text_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_text_after_delete AFTER DELETE ON catalog_product_entity_text FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_entity_tier_price`
--
DROP TRIGGER IF EXISTS trg_catalog_product_entity_tier_price_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_tier_price_after_insert AFTER INSERT ON catalog_product_entity_tier_price FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_tier_price_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_tier_price_after_update AFTER UPDATE ON catalog_product_entity_tier_price FOR EACH ROW
BEGIN
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`all_groups` <=> OLD.`all_groups`) OR NOT(NEW.`customer_group_id` <=> OLD.`customer_group_id`) OR NOT(NEW.`qty` <=> OLD.`qty`) OR NOT(NEW.`value` <=> OLD.`value`) OR NOT(NEW.`percentage_value` <=> OLD.`percentage_value`) OR NOT(NEW.`website_id` <=> OLD.`website_id`)) THEN INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`all_groups` <=> OLD.`all_groups`) OR NOT(NEW.`customer_group_id` <=> OLD.`customer_group_id`) OR NOT(NEW.`qty` <=> OLD.`qty`) OR NOT(NEW.`value` <=> OLD.`value`) OR NOT(NEW.`percentage_value` <=> OLD.`percentage_value`) OR NOT(NEW.`website_id` <=> OLD.`website_id`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_tier_price_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_tier_price_after_delete AFTER DELETE ON catalog_product_entity_tier_price FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_entity_varchar`
--
DROP TRIGGER IF EXISTS trg_catalog_product_entity_varchar_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_varchar_after_insert AFTER INSERT ON catalog_product_entity_varchar FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_varchar_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_varchar_after_update AFTER UPDATE ON catalog_product_entity_varchar FOR EACH ROW
BEGIN
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
IF (NOT(NEW.`value_id` <=> OLD.`value_id`) OR NOT(NEW.`attribute_id` <=> OLD.`attribute_id`) OR NOT(NEW.`store_id` <=> OLD.`store_id`) OR NOT(NEW.`entity_id` <=> OLD.`entity_id`) OR NOT(NEW.`value` <=> OLD.`value`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`entity_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_entity_varchar_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_entity_varchar_after_delete AFTER DELETE ON catalog_product_entity_varchar FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`entity_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`entity_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_link`
--
DROP TRIGGER IF EXISTS trg_catalog_product_link_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_link_after_insert AFTER INSERT ON catalog_product_link FOR EACH ROW
BEGIN
INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_link_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_link_after_update AFTER UPDATE ON catalog_product_link FOR EACH ROW
BEGIN
IF (NOT(NEW.`link_id` <=> OLD.`link_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`linked_product_id` <=> OLD.`linked_product_id`) OR NOT(NEW.`link_type_id` <=> OLD.`link_type_id`)) THEN INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`link_id` <=> OLD.`link_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`linked_product_id` <=> OLD.`linked_product_id`) OR NOT(NEW.`link_type_id` <=> OLD.`link_type_id`)) THEN INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`link_id` <=> OLD.`link_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`linked_product_id` <=> OLD.`linked_product_id`) OR NOT(NEW.`link_type_id` <=> OLD.`link_type_id`)) THEN INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`link_id` <=> OLD.`link_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`linked_product_id` <=> OLD.`linked_product_id`) OR NOT(NEW.`link_type_id` <=> OLD.`link_type_id`)) THEN INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`link_id` <=> OLD.`link_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`linked_product_id` <=> OLD.`linked_product_id`) OR NOT(NEW.`link_type_id` <=> OLD.`link_type_id`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_link_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_link_after_delete AFTER DELETE ON catalog_product_link FOR EACH ROW
BEGIN
INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalog_product_attribute_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalogrule_product_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`product_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_super_link`
--
DROP TRIGGER IF EXISTS trg_catalog_product_super_link_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_super_link_after_insert AFTER INSERT ON catalog_product_super_link FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_super_link_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_super_link_after_update AFTER UPDATE ON catalog_product_super_link FOR EACH ROW
BEGIN
IF (NOT(NEW.`link_id` <=> OLD.`link_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`parent_id` <=> OLD.`parent_id`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_super_link_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_super_link_after_delete AFTER DELETE ON catalog_product_super_link FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`product_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalog_product_website`
--
DROP TRIGGER IF EXISTS trg_catalog_product_website_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_website_after_insert AFTER INSERT ON catalog_product_website FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_website_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_website_after_update AFTER UPDATE ON catalog_product_website FOR EACH ROW
BEGIN
IF (NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`website_id` <=> OLD.`website_id`)) THEN INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`website_id` <=> OLD.`website_id`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalog_product_website_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalog_product_website_after_delete AFTER DELETE ON catalog_product_website FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalog_product_category_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`product_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `cataloginventory_stock_item`
--
DROP TRIGGER IF EXISTS trg_cataloginventory_stock_item_after_insert;
delimiter ;;
CREATE  TRIGGER trg_cataloginventory_stock_item_after_insert AFTER INSERT ON cataloginventory_stock_item FOR EACH ROW
BEGIN
INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`product_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_cataloginventory_stock_item_after_update;
delimiter ;;
CREATE  TRIGGER trg_cataloginventory_stock_item_after_update AFTER UPDATE ON cataloginventory_stock_item FOR EACH ROW
BEGIN
IF (NOT(NEW.`item_id` <=> OLD.`item_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`stock_id` <=> OLD.`stock_id`) OR NOT(NEW.`qty` <=> OLD.`qty`) OR NOT(NEW.`min_qty` <=> OLD.`min_qty`) OR NOT(NEW.`use_config_min_qty` <=> OLD.`use_config_min_qty`) OR NOT(NEW.`is_qty_decimal` <=> OLD.`is_qty_decimal`) OR NOT(NEW.`backorders` <=> OLD.`backorders`) OR NOT(NEW.`use_config_backorders` <=> OLD.`use_config_backorders`) OR NOT(NEW.`min_sale_qty` <=> OLD.`min_sale_qty`) OR NOT(NEW.`use_config_min_sale_qty` <=> OLD.`use_config_min_sale_qty`) OR NOT(NEW.`max_sale_qty` <=> OLD.`max_sale_qty`) OR NOT(NEW.`use_config_max_sale_qty` <=> OLD.`use_config_max_sale_qty`) OR NOT(NEW.`is_in_stock` <=> OLD.`is_in_stock`) OR NOT(NEW.`low_stock_date` <=> OLD.`low_stock_date`) OR NOT(NEW.`notify_stock_qty` <=> OLD.`notify_stock_qty`) OR NOT(NEW.`use_config_notify_stock_qty` <=> OLD.`use_config_notify_stock_qty`) OR NOT(NEW.`manage_stock` <=> OLD.`manage_stock`) OR NOT(NEW.`use_config_manage_stock` <=> OLD.`use_config_manage_stock`) OR NOT(NEW.`stock_status_changed_auto` <=> OLD.`stock_status_changed_auto`) OR NOT(NEW.`use_config_qty_increments` <=> OLD.`use_config_qty_increments`) OR NOT(NEW.`qty_increments` <=> OLD.`qty_increments`) OR NOT(NEW.`use_config_enable_qty_inc` <=> OLD.`use_config_enable_qty_inc`) OR NOT(NEW.`enable_qty_increments` <=> OLD.`enable_qty_increments`) OR NOT(NEW.`is_decimal_divided` <=> OLD.`is_decimal_divided`) OR NOT(NEW.`website_id` <=> OLD.`website_id`)) THEN INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`item_id` <=> OLD.`item_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`stock_id` <=> OLD.`stock_id`) OR NOT(NEW.`qty` <=> OLD.`qty`) OR NOT(NEW.`min_qty` <=> OLD.`min_qty`) OR NOT(NEW.`use_config_min_qty` <=> OLD.`use_config_min_qty`) OR NOT(NEW.`is_qty_decimal` <=> OLD.`is_qty_decimal`) OR NOT(NEW.`backorders` <=> OLD.`backorders`) OR NOT(NEW.`use_config_backorders` <=> OLD.`use_config_backorders`) OR NOT(NEW.`min_sale_qty` <=> OLD.`min_sale_qty`) OR NOT(NEW.`use_config_min_sale_qty` <=> OLD.`use_config_min_sale_qty`) OR NOT(NEW.`max_sale_qty` <=> OLD.`max_sale_qty`) OR NOT(NEW.`use_config_max_sale_qty` <=> OLD.`use_config_max_sale_qty`) OR NOT(NEW.`is_in_stock` <=> OLD.`is_in_stock`) OR NOT(NEW.`low_stock_date` <=> OLD.`low_stock_date`) OR NOT(NEW.`notify_stock_qty` <=> OLD.`notify_stock_qty`) OR NOT(NEW.`use_config_notify_stock_qty` <=> OLD.`use_config_notify_stock_qty`) OR NOT(NEW.`manage_stock` <=> OLD.`manage_stock`) OR NOT(NEW.`use_config_manage_stock` <=> OLD.`use_config_manage_stock`) OR NOT(NEW.`stock_status_changed_auto` <=> OLD.`stock_status_changed_auto`) OR NOT(NEW.`use_config_qty_increments` <=> OLD.`use_config_qty_increments`) OR NOT(NEW.`qty_increments` <=> OLD.`qty_increments`) OR NOT(NEW.`use_config_enable_qty_inc` <=> OLD.`use_config_enable_qty_inc`) OR NOT(NEW.`enable_qty_increments` <=> OLD.`enable_qty_increments`) OR NOT(NEW.`is_decimal_divided` <=> OLD.`is_decimal_divided`) OR NOT(NEW.`website_id` <=> OLD.`website_id`)) THEN INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
IF (NOT(NEW.`item_id` <=> OLD.`item_id`) OR NOT(NEW.`product_id` <=> OLD.`product_id`) OR NOT(NEW.`stock_id` <=> OLD.`stock_id`) OR NOT(NEW.`qty` <=> OLD.`qty`) OR NOT(NEW.`min_qty` <=> OLD.`min_qty`) OR NOT(NEW.`use_config_min_qty` <=> OLD.`use_config_min_qty`) OR NOT(NEW.`is_qty_decimal` <=> OLD.`is_qty_decimal`) OR NOT(NEW.`backorders` <=> OLD.`backorders`) OR NOT(NEW.`use_config_backorders` <=> OLD.`use_config_backorders`) OR NOT(NEW.`min_sale_qty` <=> OLD.`min_sale_qty`) OR NOT(NEW.`use_config_min_sale_qty` <=> OLD.`use_config_min_sale_qty`) OR NOT(NEW.`max_sale_qty` <=> OLD.`max_sale_qty`) OR NOT(NEW.`use_config_max_sale_qty` <=> OLD.`use_config_max_sale_qty`) OR NOT(NEW.`is_in_stock` <=> OLD.`is_in_stock`) OR NOT(NEW.`low_stock_date` <=> OLD.`low_stock_date`) OR NOT(NEW.`notify_stock_qty` <=> OLD.`notify_stock_qty`) OR NOT(NEW.`use_config_notify_stock_qty` <=> OLD.`use_config_notify_stock_qty`) OR NOT(NEW.`manage_stock` <=> OLD.`manage_stock`) OR NOT(NEW.`use_config_manage_stock` <=> OLD.`use_config_manage_stock`) OR NOT(NEW.`stock_status_changed_auto` <=> OLD.`stock_status_changed_auto`) OR NOT(NEW.`use_config_qty_increments` <=> OLD.`use_config_qty_increments`) OR NOT(NEW.`qty_increments` <=> OLD.`qty_increments`) OR NOT(NEW.`use_config_enable_qty_inc` <=> OLD.`use_config_enable_qty_inc`) OR NOT(NEW.`enable_qty_increments` <=> OLD.`enable_qty_increments`) OR NOT(NEW.`is_decimal_divided` <=> OLD.`is_decimal_divided`) OR NOT(NEW.`website_id` <=> OLD.`website_id`)) THEN INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (NEW.`product_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_cataloginventory_stock_item_after_delete;
delimiter ;;
CREATE  TRIGGER trg_cataloginventory_stock_item_after_delete AFTER DELETE ON cataloginventory_stock_item FOR EACH ROW
BEGIN
INSERT IGNORE INTO `cataloginventory_stock_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalog_product_price_cl` (`entity_id`) VALUES (OLD.`product_id`);
INSERT IGNORE INTO `catalogsearch_fulltext_cl` (`entity_id`) VALUES (OLD.`product_id`);
END
;;
delimiter ;

--
-- Triggers structure for table `catalogrule`
--
DROP TRIGGER IF EXISTS trg_catalogrule_after_insert;
delimiter ;;
CREATE  TRIGGER trg_catalogrule_after_insert AFTER INSERT ON catalogrule FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogrule_rule_cl` (`entity_id`) VALUES (NEW.`rule_id`);
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalogrule_after_update;
delimiter ;;
CREATE  TRIGGER trg_catalogrule_after_update AFTER UPDATE ON catalogrule FOR EACH ROW
BEGIN
IF (NOT(NEW.`rule_id` <=> OLD.`rule_id`) OR NOT(NEW.`name` <=> OLD.`name`) OR NOT(NEW.`description` <=> OLD.`description`) OR NOT(NEW.`from_date` <=> OLD.`from_date`) OR NOT(NEW.`to_date` <=> OLD.`to_date`) OR NOT(NEW.`is_active` <=> OLD.`is_active`) OR NOT(NEW.`conditions_serialized` <=> OLD.`conditions_serialized`) OR NOT(NEW.`actions_serialized` <=> OLD.`actions_serialized`) OR NOT(NEW.`stop_rules_processing` <=> OLD.`stop_rules_processing`) OR NOT(NEW.`sort_order` <=> OLD.`sort_order`) OR NOT(NEW.`simple_action` <=> OLD.`simple_action`) OR NOT(NEW.`discount_amount` <=> OLD.`discount_amount`)) THEN INSERT IGNORE INTO `catalogrule_rule_cl` (`entity_id`) VALUES (NEW.`rule_id`); END IF;
END
;;
delimiter ;
DROP TRIGGER IF EXISTS trg_catalogrule_after_delete;
delimiter ;;
CREATE  TRIGGER trg_catalogrule_after_delete AFTER DELETE ON catalogrule FOR EACH ROW
BEGIN
INSERT IGNORE INTO `catalogrule_rule_cl` (`entity_id`) VALUES (OLD.`rule_id`);
END
;;
delimiter ;


