Magento Forum

   
SQLSTATE[HY000]: General error: 1030 Got error -1
 
ditiymeri
Jr. Member
 
Total Posts:  1
Joined:  2012-12-07
 

Hello!
I was trying do delete all magento categories, using some php script like:

$categories = $db_read->fetchCol("SELECT entity_id FROM “ . $resource->getTableName("catalog_category_entity") . “ WHERE entity_id>1 ORDER BY entity_id DESC");

foreach ($categories as $category_id) {
try {
Mage::getModel("catalog/category")->load($category_id)->delete();
} catch (Exception $e) {
echo $e->getMessage() . “\n”;
}
}

Some of categories are not deleted.In browser is displaying SQLSTATE[HY000]: General error: 1030 Got error -1.
I cant even delete those categories from admin page.

Can anybody help me solving this?

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