SQL Has Not Run on Installation

Overview
 
If you see the error below, or find that attributes are missing that you expect on the installation (and are not found under the Attributes section in admin) it is likely that the extension SQL installation script has not run.
 
This error results from a race condition in Magento, where the code is unable to pick up the sql file when attempting to install. We only see this on <1% of installations, but when it happens it is not easy to resolve. We apologise for this, and are working with Magento to make the installation side more solid so this problem doesnt occur.
 
Resolution
 

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.

  1. Take full db backup
  2. Find the database table 'core_resource'
  3. Browse the table, looking for the entry causing the issue (e.g. productmatrix_setup)
  4. Remove that entry alone
  5. Ensure cache is switched off
  6. Refresh the frontend
  7. Check to see that install script has now run and created tables
Alternatively, we have a script which allows you to delete the core_resource table. 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.

Disclaimer - Do not use this script unless you are confident that you know what you are doing. WebShopApps cannot be held responsible for the outcomes of using this script. 
  1. Take a full db backup
  2. Add the script file (setResource.php) to the base of your Magento install. 
  3. Navigate to your base Magento url followed by '/setResource.php' (eg. www.magento.com/setResource.php).
  4. Select your extension from the dropdown. If you cannot see your extension then you can add the core_resource code manually (eg. productmatrix_setup).
  5. Click on the 'Show Current Resource Version' button to continue.
  6. Now click on the 'delete' button to delete the row in core_resource that corresponds to your extension.
  7. Refresh the frontend.
  8. Ensure that the script has now run correctly - check that the attributes have been created. 
  9. Remove the script file after use.
ċ
setResource.php
(5k)
Unknown user,
Apr 17, 2012, 4:28 AM
Comments