-
Notifications
You must be signed in to change notification settings - Fork 116
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
Using newQuery() is deprecated. Instead, use insertQuery()
, deleteQuery()
, selectQuery()
or updateQuery()
#651
Comments
Hi, |
@mcube27 No it won't. If you don't want to see deprecations you can turn them off. But you'll need to address the deprecations before you can upgrade. Upgrading migrations may also help as currently migrations is not using |
We use migration sometimes to make sql queries using That is why I asked if it will be corrected ? |
This aligns the interface we have in the 4.x branch, and also gives a solution to #651 for applications that want to not have any deprecations.
After attempting to fix this with #731, I don't think there is a reasonable solution for this deprecation warning. Phinx providers the If you want to get rid of the deprecations now you'd have to alter your usage of migrations to $query = $this->adapter->getDecoratedConnection()->selectQuery(); |
Having this method will improve compatibility with historical migrations. Refs #651
Thanks for the update. We have scheduled the migration to CakePHP 5 for the end of this year. I guess to replace the old The changes from your PR are a good reference guess. Is there any documentation about |
No, but it will return a |
Perfect, many thanks |
This is a (multiple allowed):
bug
enhancement
feature-discussion (RFC)
CakePHP Version: 4.5.0
Migrations plugin version: 3.9.0
@stable in composer.json
Bake plugin version (if relevant): EXACT RELEASE VERSION OR COMMIT HASH, HERE.
Database server mysql Ver 8.0.34-0ubuntu0.22.04.1
PHP Version: PHP 8.1.2-1ubuntu2.14
Platform / OS: Ubuntu and RHEL
What you did
When using CakePHP 4.5.0 with the migration plugin, I get the following deprecated messages
This is
/opt/openitc/frontend/config/Seeds/InstallSeed.php, line 153
:Expected Behavior
No deprecated messages
The text was updated successfully, but these errors were encountered: