Cannot migrate stored procedure
See original GitHub issueI’m submitting a…
- Bug report
- Feature request
- Question
Current behavior
When created a stored procedure it’s necessary to change the delimiter e.g. DELIMITER $$
However, when using a SQL-file it returns ER_PARSE_ERROR:
Expected behavior
Be able to change the delimiter, create the SP and return delimiter back to standard ;
Minimal reproduction of the problem with instructions
DELIMITER // CREATE PROCEDURE testProc() BEGIN SELECT 1; END // DELIMITER ;
What is the motivation / use case for changing the behavior?
Cannot create or migrate stored procedures
Environment
db-migrate version: 0.11.5
db-migrate-mysql with versions: 1.1.10
Additional information:
- Node version: 8.12.0
- Platform: Mac
Others:
<bountysource-plugin>
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource. </bountysource-plugin>
Issue Analytics
- State:
- Created 4 years ago
- Reactions:2
- Comments:13 (6 by maintainers)
Top Results From Across the Web
Stored procedure can not be parsed during migration
I'm using the api of flyway 1.7 for migrating a hsql database. I have some problems with stored procedures. The following script works...
Read more >Unable to migrate views, routines and stored procedures from ...
I tried migrating the data from MSSQL server database(Windows) to mariadb(Linux) using Mysql Workbench. Workbench migrated few tables but ...
Read more >Migrate stored procedures using SCT
We will now migrate some stored procedures using SCT, directly to Aurora (MySQL) · Navigate to Settings in the menu, and click Mapping...
Read more >SSMA - error when converting function and stored procedure
I can able to migrate table and the data from Oracle to MS SQL using the SSMA tool, I have problem when migrating...
Read more >Migrate SQL server database to mysql with store procedure
Either find a better tool, or migrate the stored procedures manually: MySQL :: MySQL 8.0 Reference Manual :: 13.1.17 CREATE PROCEDURE and ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
after further tests I can see that this isn’t actually an issue for me at all. I have my connection config set to
multipleStatements
true
and can indeed run multiple statements with stored procedures in the same sql file such as this one:no need for a delimiter change at all
using mysql I can confirm, with
multipleStatements
set to true in the database.json and no delimiters, I was able to have a migration like: