Try the Demo

Magento Forum

   
Integrity constraint violation: 1452 and unable to save the app
 
Jess Ang
Jr. Member
 
Total Posts:  5
Joined:  2010-09-14
 

I’ve installed the Magento Mobile extension (https://www.magentocommerce.com/magento_mobile/122911_rev_121425/Mage_XmlConnect-1.4.2.0.tgz). on my 1.4.2.0 store and it seems to have installed correctly however when I go to Add Application I get this error:

\\\"Unable to save the app.\\\”

When I check the exception log, it state

SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`MYMAGENTO/xmlconnect_application`, CONSTRAINT `FK_XMLCONNECT_APPLICAION_STORE` FOREIGN KEY (`store_id`) REFERENCES `core_store` (`store_id`) ON DELETE SET NULL ON UPDATE SET NULL)\\\’

Please can you point me in the direction to get this working?

Thanks!!!

 
Magento Community Magento Community
Magento Community
Magento Community
 
Enase
Jr. Member
 
Total Posts:  19
Joined:  2010-05-11
 

Hello Jess Ang,

You can solve your problem by executing the sql query (see below), but pay attantion that all your magento mobile data will be lost.

SET foreign_key_checks = 0;
DROP TABLE `xmlconnect_application`, `xmlconnect_history`, `xmlconnect_notification_template`, `xmlconnect_queue`, `xmlconnect_config_data`;
DELETE FROM `YOUR_DATABASE_NAME_HERE`.`core_resource` WHERE `core_resource`.`code` = ’xmlconnect_setup’;
SET foreign_key_checks = 1;

Notice: Replace YOUR_DATABASE_NAME_HERE in the query with your data base name.

Thanks!

 
Magento Community Magento Community
Magento Community
Magento Community
 
Jess Ang
Jr. Member
 
Total Posts:  5
Joined:  2010-09-14
 

Hi Enase,

Thanks for your help.

I have run the sql but still could not save the mobile app....HELP!!!!

The same error coming out after save the app.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Jess Ang
Jr. Member
 
Total Posts:  5
Joined:  2010-09-14
 

Hi,

I fix the ‘unable to save app’ error but now another error comes out.

The mobile app just crash after magento store mobile finish loaded.

Help!!!

 
Magento Community Magento Community
Magento Community
Magento Community
 
NickTischenko
Magento Team
 
Total Posts:  14
Joined:  2010-10-22
 

What device are you testing on? Also could you please give me your store url and application code? I’d be happy to help you.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Jess Ang
Jr. Member
 
Total Posts:  5
Joined:  2010-09-14
 

Hi,

Thanks for your help.

I am using iphone device, and

my store url: http://expoj.stagingilook.co.nz/xmlconnect
code : defiph1

Thanks

 
Magento Community Magento Community
Magento Community
Magento Community
 
NickTischenko
Magento Team
 
Total Posts:  14
Joined:  2010-10-22
 

Thanks for the information.

We couldn’t reproduce the issue on our latest version of the app.

However, it can be reproduced on our preview app. We are sorry for the inconvenience. Our preview application will be updated in the AppStore shortly.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top