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

Queries in import.sql can't be split to multiple lines anymore #11566

Closed
jmartisk opened this issue Aug 24, 2020 · 2 comments
Closed

Queries in import.sql can't be split to multiple lines anymore #11566

jmartisk opened this issue Aug 24, 2020 · 2 comments
Labels
area/hibernate-orm Hibernate ORM kind/bug Something isn't working
Milestone

Comments

@jmartisk
Copy link
Contributor

With the latest snapshot (019f4e7e63; it doesn't happen in 1.7.0), I noticed that if I have queries in my import.sql that are split into multiple lines like

insert into Person (gender, name, id)
values ('MALE', 'Jimbo', nextval('hibernate_sequence'));

Then each line is executed as if it were a full query, and the application breaks in this case.
For preserving readability, we should keep allowing splitting queries into multiple lines.

@jmartisk jmartisk added kind/bug Something isn't working area/hibernate-orm Hibernate ORM labels Aug 24, 2020
@gsmet
Copy link
Member

gsmet commented Aug 24, 2020

@Sanne looks like your patch didn't work as expected?

@gsmet gsmet added this to the 1.7.1.Final milestone Aug 24, 2020
@gsmet
Copy link
Member

gsmet commented Aug 24, 2020

I think the issue is there: https://github.com/quarkusio/quarkus/pull/11353/files#diff-62f3a6c6771d8f3a4819eb119de072ecR12 .

The INSTANCE should be an instance of QuarkusImportSqlCommandExtractorInitiator.

Let me work on a patch (and add a test).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/hibernate-orm Hibernate ORM kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants