Skip to content

DATAJDBC-264 - Fix insert query for empty nonIdColumnNames #88

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

Closed
wants to merge 1 commit into from

Conversation

sunnyone
Copy link

SqlGenerator.createInsertSql fails to generate sql when nonIdColumnNames is empty.
This method outputs like this:

INSERT INTO sample_table () VALUES (:)

This pull request fixes this behaivor. It uses the way of createUpdateSql instead of Collectors.joining(delimiter, prefix, suffix).

@pivotal-issuemaster
Copy link

@sunnyone Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

@schauder schauder changed the title Fix insert query for empty nonIdColumnNames DATAJDBC-264 - Fix insert query for empty nonIdColumnNames Sep 18, 2018
@schauder
Copy link
Contributor

@sunnyone could you please provide your name written with Latin characters, so I include it in an @author tag?

@pivotal-issuemaster
Copy link

@sunnyone Thank you for signing the Contributor License Agreement!

@sunnyone
Copy link
Author

My name is Yoichi Imai. Thanks.

schauder pushed a commit that referenced this pull request Sep 18, 2018
When an entity consists only of it's id column, the value list contained a single `:`.
This commit fixes this.

Original pull request: #88.
schauder added a commit that referenced this pull request Sep 18, 2018
Added a test.
Added an author tag.
Minor formatting.

Original pull request: #88.
@schauder
Copy link
Contributor

Thanks, that is polished and merged.

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

Successfully merging this pull request may close these issues.

3 participants