New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CakePHP 3.0 Undefined index: on_update #6230
Comments
What version of SQLite do you have? |
Version of SQLite is 3.5.9 (if is too old for DebugKit, u could add info about it on welcome screen) |
I don't think that's too old, but I would have also expected that reflecting foreign keys would work too. |
Any update on the above issue? I am too getting the same issue. I am also not using sqllite and I am using only mysql. |
Foreign keys are supported since SQLite 3.6.19 I would suggest looking into updating your sqlite or PHP version while this issue is investigated. |
@jhon312020 DebugKit uses SQLite which is probably why you are seeing this error even though you are using MySQL for your application. |
PHP Version 5.4.10 - Will cakephp 3.0.1 will work with this php version? On making app.php "debug" value to true - I am getting the issue "unable to server this request". |
@jhon312020 read my comment here: #6230 (comment) |
I am not even created a database it is just a fresh copy and I am going to use only mysql. I have also commented the plugin debugkit which uses sqlite by default. PHP Version 5.4.10 - Will cakephp 3.0.1 will work with this php version? |
@jhon312020 You can also configure debugkit to sue mysql if you are having troubles with sqlite http://book.cakephp.org/3.0/en/debug-kit.html#database-configuration |
@lorenzo - Thanks for your timely responses. PHP Version 5.4.10 - Will cakephp 3.0.1 will work with this php version? |
@jhon312020 Your MySQL Client doesn't matter too much (The server version is the important one), requirements document states 5.1.10. Easiest way to find out if it will work is to try it! |
@dakota I tried but getting the following |
@jhon312020 That's got nothing to do with MySQL, see #6230 (comment) You need to updated your Sqlite version, or configure DebugKit to use MySQL. |
@dakota I added the debug_kit to app.php pointing to mysql. Then also getting the same result Notice (8): Undefined index: on_update [CORE/src/Database/Schema/SqliteSchema.php, line 214] |
@jhon312020 perhaps drop by on irc to get support on getting things to work and keep this issue tracker for actual bugs. |
SQLite prior to 3.6 does not support reflecting foreign key update/delete properties. Conditionally parsing them is better than notice errors. Refs #6230
Fixed in #6302 |
Sometimes get those errors:
Notice (8): Undefined index: on_update [CORE/src/Database/Schema/SqliteSchema.php, line 214]
Notice (8): Undefined index: on_delete [CORE/src/Database/Schema/SqliteSchema.php, line 215]
I use mysql and php 5.5
Logs from debug.log:
2015-03-31 15:02:20 Notice: Notice (8): Undefined index: on_update in [/home/users/muzyczni/public_html/vendor/cakephp/cakephp/src/Database/Schema/SqliteSchema.php, line 214]
Trace:
Cake\Error\BaseErrorHandler::handleError() - CORE/src/Error/BaseErrorHandler.php, line 138
Cake\Database\Schema\SqliteSchema::convertForeignKeyDescription() - CORE/src/Database/Schema/SqliteSchema.php, line 214
Cake\Database\Schema\Collection::_reflect() - CORE/src/Database/Schema/Collection.php, line 133
Cake\Database\Schema\Collection::describe() - CORE/src/Database/Schema/Collection.php, line 102
Cake\Database\Schema\CachedCollection::describe() - CORE/src/Database/Schema/CachedCollection.php, line 65
Cake\ORM\Table::schema() - CORE/src/ORM/Table.php, line 422
Cake\ORM\Marshaller::one() - CORE/src/ORM/Marshaller.php, line 107
Cake\ORM\Table::newEntity() - CORE/src/ORM/Table.php, line 1953
Cake\ORM\Association::__call() - CORE/src/ORM/Association.php, line 835
Cake\ORM\Association\HasMany::newEntity() - ROOT/vendor/cakephp/debug_kit/src/Routing/Filter/DebugBarFilter.php, line 207
DebugKit\Routing\Filter\DebugBarFilter::afterDispatch() - ROOT/vendor/cakephp/debug_kit/src/Routing/Filter/DebugBarFilter.php, line 207
Cake\Event\EventManager::_callListener() - CORE/src/Event/EventManager.php, line 385
Cake\Event\EventManager::dispatch() - CORE/src/Event/EventManager.php, line 351
Cake\Routing\Dispatcher::dispatchEvent() - CORE/src/Event/EventManagerTrait.php, line 78
Cake\Routing\Dispatcher::dispatch() - CORE/src/Routing/Dispatcher.php, line 92
[main] - ROOT/webroot/index.php, line 37
2015-03-31 15:02:20 Notice: Notice (8): Undefined index: on_delete in [/home/users/muzyczni/public_html/vendor/cakephp/cakephp/src/Database/Schema/SqliteSchema.php, line 215]
Trace:
Cake\Error\BaseErrorHandler::handleError() - CORE/src/Error/BaseErrorHandler.php, line 138
Cake\Database\Schema\SqliteSchema::convertForeignKeyDescription() - CORE/src/Database/Schema/SqliteSchema.php, line 215
Cake\Database\Schema\Collection::_reflect() - CORE/src/Database/Schema/Collection.php, line 133
Cake\Database\Schema\Collection::describe() - CORE/src/Database/Schema/Collection.php, line 102
Cake\Database\Schema\CachedCollection::describe() - CORE/src/Database/Schema/CachedCollection.php, line 65
Cake\ORM\Table::schema() - CORE/src/ORM/Table.php, line 422
Cake\ORM\Marshaller::one() - CORE/src/ORM/Marshaller.php, line 107
Cake\ORM\Table::newEntity() - CORE/src/ORM/Table.php, line 1953
Cake\ORM\Association::__call() - CORE/src/ORM/Association.php, line 835
Cake\ORM\Association\HasMany::newEntity() - ROOT/vendor/cakephp/debug_kit/src/Routing/Filter/DebugBarFilter.php, line 207
DebugKit\Routing\Filter\DebugBarFilter::afterDispatch() - ROOT/vendor/cakephp/debug_kit/src/Routing/Filter/DebugBarFilter.php, line 207
Cake\Event\EventManager::_callListener() - CORE/src/Event/EventManager.php, line 385
Cake\Event\EventManager::dispatch() - CORE/src/Event/EventManager.php, line 351
Cake\Routing\Dispatcher::dispatchEvent() - CORE/src/Event/EventManagerTrait.php, line 78
Cake\Routing\Dispatcher::dispatch() - CORE/src/Routing/Dispatcher.php, line 92
[main] - ROOT/webroot/index.php, line 37
The text was updated successfully, but these errors were encountered: