sql-migrate icon indicating copy to clipboard operation
sql-migrate copied to clipboard

Comments should be ignored for detecting commands boundaries

Open tamalsaha opened this issue 7 years ago • 2 comments

I have a SQL file that ends with a commented out line. SQL migration fails with the following error:

I0404 16:17:30.659541   22029 error.go:293] Error:INTERNAL ERROR: The last statement must be ended by a semicolon or '-- +migrate StatementEnd' marker.

tamalsaha avatar Apr 04 '17 23:04 tamalsaha

Same error when a comment is present between -- +migrate StatementEnd and -- +migrate Down

maxatome avatar Jun 16 '17 07:06 maxatome

Seems to be OK with 48fb62e01c6f5d73d6650c4c9f54d1141b3c79a1. Sorry for the noise.

maxatome avatar Jun 16 '17 07:06 maxatome