Skip to content
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

Parser issue for Sybase ASE for keyword GOTO #2774

Closed
ltwesley opened this issue Apr 19, 2020 · 1 comment
Closed

Parser issue for Sybase ASE for keyword GOTO #2774

ltwesley opened this issue Apr 19, 2020 · 1 comment

Comments

@ltwesley
Copy link
Contributor

ltwesley commented Apr 19, 2020

Which version and edition of Flyway are you using?

6.3.3 (community and pro edition)

If this is not the latest version, can you reproduce the issue with the latest one as well?

(Many bugs are fixed in newer releases and upgrading will often resolve the issue)
Yes the issue can be reproduced in the latest. (v6.3.3)

Which client are you using? (Command-line, Java API, Maven plugin, Gradle plugin)

Command Line

Which database are you using (type & version)?

Sybase ASE 16.2

Which operating system are you using?

Linux

What did you do?

(Please include the content causing the issue, any relevant configuration settings, the SQL statement that failed (if relevant) and the command you ran.)
SQL with GOTO keywords results in a 'column not found' error when running migrate command. The parser is splitting the GOTO into two keywords (GO, TO)

declare @count smallint
select @count = 1
restart:
  print 'yes'
select @count = @count + 1
while @count <= 4
  goto restart
What did you expect to see?

No errors when running migrate command. In the code snippet above 'yes' should be printed 3x

What did you see instead?
Migration R__wes.sql failed
---------------------------
SQL State  : 37000
Error Code : 102
Message    : Incorrect syntax near '4'.
Line       : 1
Statement  : declare @count smallint
select @count = 1
restart:
  print 'yes'
select @count = @count + 1
while @count <= 4
ltwesley added a commit to ltwesley/flyway that referenced this issue Apr 19, 2020
@Lyeeedar Lyeeedar self-assigned this Apr 20, 2020
@Lyeeedar Lyeeedar added this to the 6.4.1 milestone Apr 22, 2020
@Lyeeedar
Copy link
Contributor

Lyeeedar commented Apr 22, 2020

This will be in flyway 6.4.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants