-
-
Notifications
You must be signed in to change notification settings - Fork 388
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
"SQLSTATE[IMSSP]: This function is not implemented by this driver" with MS SQL and doctrine/migrations 3.3.2 #1214
Comments
@acelaya this probably has to do with what I did in #1210 … I don't understand why though:
How could this line possibly result in an exception from SQL Server? It does not execute any SQL, does it? Also, please provide a full stack trace as describe in https://symfony.com/doc/current/contributing/code/stack_trace.html#stack-traces-in-the-cli |
Sorry @greg0ire, I didn't see your request to add the stack trace. I have updated the ticket description after running the command with |
I'm starting to think using What driver are you using, by the way? |
pdo_sqlsrv |
I found this: microsoft/msphpsql#1306 The issue you are experiencing is with the driver you are using (it is buggy, since it breaks `method_exists). In the meantime, I don't think it's fair to have a workaround in |
Thanks! I will follow-up that issue there. I'm already waiting for that version for other issues, so it's ok. Agree on no workarounds. This is too specific, and probably not so many people is using MS SQL with PHP. |
Hi @greg0ire
Sorry, but for those of us who have no alternative to use SQL Server, migrations are very useful and it is difficult to avoid using them. This bug has already been fixed in Symfony (here symfony/symfony@d65f9ee) so as not to depend on the driver solution, it could be fixed here too. The solution would be to implement something similar to what was done in Symfony, just correct a line. while (! $innermostConnection instanceof PDO && method_exists($innermostConnection, 'getWrappedConnection')) { Is it possible to do so, to be able to continue using migrations? |
It sure would be possible, but before we do that, please explain to me what prevents you from downgrading |
Ehm... nothing, hehehe, sorry, I just installed Doctrine-Migrations-Bundle and that's the reason why version 3.3.2 of doctrine/migration was installed. Thank you very much. And sorry again, I'm a bit of a newbie. |
No worries 🙂 |
I can confirm this is fixed on pdo_sqlsrv 5.10.0beta2 |
Bug Report
Summary
When trying to run the migrations via command line, using v3.3.2 and Microsoft SQL server, this error appears:
Works fine with doctrine/migrations v3.3.1, and also with v3.3.2 when using any other database engine.
Current behavior
The error described above.
How to reproduce
Using Microsoft SQL server, run
vendor/bin/doctrine-migrations migrations:migrate
.Expected behavior
Migrations are properly executing, and the migrations command succeeds.
The text was updated successfully, but these errors were encountered: