Bug #43190
Misleading exception message for incompatible database structure
Status: | Accepted | Start date: | 2012-11-21 | |
---|---|---|---|---|
Priority: | Should have | Due date: | ||
Assigned To: | Karsten Dambekalns | % Done: | 0% |
|
Category: | Persistence | |||
Target version: | TYPO3 Flow Base Distribution - 2.0.1 | |||
PHP Version: | 5.3 | Complexity: | easy | |
Has patch: | No | Affected Flow version: | Git master |
Description
If the database structure doesn't match the current schema (for example, if a table has not been created yet), a user is confronted with the following exception message:
Notice: A non well formed numeric value encountered in Data/Temporary/Development/Cache/Code/Flow_Object_Classes/TYPO3_Flow_Persistence_Doctrine_Query_Original.php line 159
On investigating the stack trace, you'll eventually find the real cause:
34 Exception::__construct("SQLSTATE[42S02]: Base table or view not found: 114…_example_bookshop_domain_model_book' doesn't exist", "42S02") 00157: return 0; 00158: } catch (\PDOException $pdoException) { 00159: throw new DatabaseConnectionException($pdoException->getMessage(), $pdoException->getCode()); 00160: } 00161: }
The user should get a more meaningful error message in theses cases
History
#1 Updated by Karsten Dambekalns over 2 years ago
- Status changed from New to Accepted
- Assigned To set to Karsten Dambekalns
#2 Updated by Karsten Dambekalns over 2 years ago
- Affected Flow version changed from Git 1.2 (master) to Git master
#3 Updated by Karsten Dambekalns almost 2 years ago
- Target version changed from 2.0 to 2.0.1