Magento can't reindex products
Hy, after i delete all products from my magento store i can't reindex anymore, i try many and many possibles but can get nothing and i don't have shl acess

i'm running this script:

http://snipt.org/vahgi6

and get this error:

Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`cambuist_l`.<result 2 when explaining filename '#sql-ff396_32d80c'>, CONSTRAINT `FK_CAT_PRD_FLAT_1_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` )' in /home/cambuist/public_html/loja/lib/Zend/Db/Statement/Pdo.php:228 Stack trace: #0 /home/cambuist/public_html/loja/lib/Zend/Db/Statement/Pdo.php(228): PDOStatement->execute(Array) #1 /home/cambuist/public_html/loja/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array) #2 /home/cambuist/public_html/loja/lib/Zend/Db/Statement.php(300): Varien_Db_Statement_Pdo_Mysql->_execute(Array) #3 /home/cambuist/public_html/loja/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array) #4 /home/cambuist/public_html/loja/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('ALTER TABLE `ca...', Array) in /home/cambuist/public_html/loja/lib/Zend/Db/Statement/Pdo.php on line 228

Magento can't reindex products
===

Hy, after i delete all products from my magento store i can't reindex anymore, i try many and many possibles but can get nothing and i don't have shl acess

i'm running this script:

http://snipt.org/vahgi6

and get this error:

Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`cambuist_l`.<result 2 when explaining filename '#sql-ff396_32d80c'>, CONSTRAINT `FK_CAT_PRD_FLAT_1_ENTT_ID_CAT_PRD_ENTT_ENTT_ID` FOREIGN KEY (`entity_id`) REFERENCES `catalog_product_entity` )' in /home/cambuist/public_html/loja/lib/Zend/Db/Statement/Pdo.php:228 Stack trace: #0 /home/cambuist/public_html/loja/lib/Zend/Db/Statement/Pdo.php(228): PDOStatement->execute(Array) #1 /home/cambuist/public_html/loja/lib/Varien/Db/Statement/Pdo/Mysql.php(110): Zend_Db_Statement_Pdo->_execute(Array) #2 /home/cambuist/public_html/loja/lib/Zend/Db/Statement.php(300): Varien_Db_Statement_Pdo_Mysql->_execute(Array) #3 /home/cambuist/public_html/loja/lib/Zend/Db/Adapter/Abstract.php(479): Zend_Db_Statement->execute(Array) #4 /home/cambuist/public_html/loja/lib/Zend/Db/Adapter/Pdo/Abstract.php(238): Zend_Db_Adapter_Abstract->query('ALTER TABLE `ca...', Array) in /home/cambuist/public_html/loja/lib/Zend/Db/Statement/Pdo.php on line 228
