Error in file:

"/var/www/vhosts/mazali.co.uk/httpdocs/app/code/core/Mage/Customer/sql/customer_setup/upgrade-" - SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'customer_flowpassword' already exists, query was: CREATE TABLE `customer_flowpassword` (
  `flowpassword_id` int UNSIGNED NOT NULL auto_increment COMMENT 'Flow password Id' ,
  `ip` varchar(50) NOT NULL COMMENT 'User IP' ,
  `email` varchar(255) NOT NULL COMMENT 'Requested email for change' ,
  `requested_date` varchar(255) NOT NULL default '0000-00-00 00:00:00' COMMENT 'Requested date for change' ,
  PRIMARY KEY (`flowpassword_id`),
) COMMENT='Customer flow password' ENGINE=INNODB charset=utf8 COLLATE=utf8_general_ci

#0 /var/www/vhosts/mazali.co.uk/httpdocs/app/code/core/Mage/Core/Model/Resource/Setup.php(644): Mage::exception('Mage_Core', 'Error in file: ...')
#1 /var/www/vhosts/mazali.co.uk/httpdocs/app/code/core/Mage/Core/Model/Resource/Setup.php(437): Mage_Core_Model_Resource_Setup->_modifyResourceDb('upgrade', '', '')
#2 /var/www/vhosts/mazali.co.uk/httpdocs/app/code/core/Mage/Core/Model/Resource/Setup.php(320): Mage_Core_Model_Resource_Setup->_upgradeResourceDb('', '')
#3 /var/www/vhosts/mazali.co.uk/httpdocs/app/code/core/Mage/Core/Model/Resource/Setup.php(235): Mage_Core_Model_Resource_Setup->applyUpdates()
#4 /var/www/vhosts/mazali.co.uk/httpdocs/app/code/core/Mage/Core/Model/App.php(428): Mage_Core_Model_Resource_Setup::applyAllUpdates()
#5 /var/www/vhosts/mazali.co.uk/httpdocs/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Model_App->_initModules()
#6 /var/www/vhosts/mazali.co.uk/httpdocs/app/Mage.php(684): Mage_Core_Model_App->run(Array)
#7 /var/www/vhosts/mazali.co.uk/httpdocs/index.php(83): Mage::run('', 'store')
#8 {main}

I am beginner can you explain slowly.

  • check if the table customer_flowpassword is empty, because the script seems to want to create a table that already exists.. if the table is empty, you can delete it and run the script again
    – Robin
    Commented Dec 9, 2016 at 11:21

1 Answer 1


It would appear the script for the upgrade is trying to create a MySQL table called 'customer_flowpassword' however this table already exists within your database.

You would have 2 options,

  1. DROP (delete) the table from the database however you might want to back this up if the table has data in it so you can import again if desired
  2. temporarily comment out the create statement in the sql script

Your Answer

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

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