- Unique Index Too Long
- SQL has already been run on this server and is causing a conflict by attempting to run twice (this is very rare and only happens when database has been manually modified)
- The frontend was updated during installation, resulting in attempt to run SQL install/upgrade before files were present
You may see errors such as:
SQLSTATE[42S02]: Base Table Or View Not Found: 1146
Before doing anything please check:
- You have installed all files correctly (including Common/Logger)
- the report in var/report, which will give you a good indication of the problem
If you find that you have an attribute missing, or tables not found you are likely to have issue 3 above, which can be resolved by rewinding the core_resource.
Manually rewind core_resource
Take the following steps to resolve the issue. We assume here you are competent with phpmyadmin, if not then get a developer who is to assist, as doing this wrong can break your magento installation.
- Take full db backup
- Find the database table ‘core_resource’
- Browse the table, looking for the entry causing the issue (e.g. productmatrix_setup)
- Remove that entry alone
- Ensure cache is switched off
- Refresh the frontend
- Check to see that install script has now run and created the missing tables and attributes
Script delete/rewind core_resource
Alternatively, we have a script which allows you to delete/rewide the core_resource entry. Please note, you will need the latest WSA Common installed for the script to run successfully. It is recommended that you contact WebShopApps to get the latest version of WSA Common and that you install it onto your site before running this script.
Delete core_resource
This should only be done if its the first time you have installed this extension.
Disclaimer – Do not use this script unless you are confident that you know what you are doing. WebShopApps cannot be held responsible for the outcome.
- Take a full db backup
- Add the script file (setResource.php) to the base of your Magento install.
- Navigate to your base Magento url followed by ‘/setResource.php’ (eg. www.magento.com/setResource.php).
- Select your extension from the dropdown. If you cannot see your extension then you can add the core_resource code manually (eg. productmatrix_setup).
- Click on the ‘Show Current Resource Version’ button to continue.
- Now click on the ‘delete’ button to delete the row in core_resource that corresponds to your extension.
- Refresh the frontend.
- Ensure that the script has now run correctly – check that the attributes have been created.
- Remove the script file after use.
Rewind Resource
Additionally the setResource contains a rewind script which can be used to roll back to an earlier version and will force Magento to run the upgrade script for the SQL.
Do not use this script unless you are-confident that you know what you are doing. WebShopApps cannot be held responsible for the outcome.
- Take a full db backup
- Add the script file (setResource.php) to the base of your Magento install
- Navigate to your base Magento url followed by ‘/setResource.php’ (eg. www.magento.com/setResource.php)
- Select your extension from the dropdown. If you cannot see your extension then you can add the core_resource code manually (eg. productmatrix_setup).If you cannot see the extension in the drop down list you need to look in app/code/community/webhopapps/extension name/etc/config.xml. In this file you will want to search for resourceModel and note the first name in the middle and add and append _setup after the name. So for example <resourceModel>shipusa_resource</resourceModel> you would be shipusa_setup. You would then enter this into the other field
- Click on the ‘Show Current Resource Version’ button to continue
- Note the module version and check to see if it is set to the version before e.g current module version is 1.0.6 you would roll-back to 1.0.5
- Click rewind
- Refresh the frontend
- Ensure that the script has now run correctly – check that the attributes have been created
- Remove the script file after use
Further Help
If problems remain:
- Identify the actual error. If just a report number is given then go find the report from var/reports directory under you Magento installation filesystem
- Disable extension, further information here
- Contact WebShopApps Support with your order details, error report and problem seen for us to diagnose the issue