-
Notifications
You must be signed in to change notification settings - Fork 229
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
New feature?: Bind a bean to an Insert or Update query #19
Comments
Hi jsnoriegam, I have had these thoughts myself. The only reason I haven't implemented it, is because I haven't had the time, and no one (before you) have asked for it. If you feel like implementing it, you are more than welcome :) Otherwise I will put it in the todo list for one of the next versions. |
This is a draft implementation but it works for me: |
Nice :) |
Unit test ready, and a few corrections to the new bind method. |
Merged into master. Thanks a lot :) |
I know this is not a ORM and that's what is good about this project, but just as you can map a bean from a select result, i think it would be good to bind a bean to an update or insert query...
Something like .createQuery("UPDATE clients SET date = :date, name = :name, regn = :regn, active = :active WHERE id = :id").bind(client).executeUpdate();
bindig all the attributes of client as paramaters (Asuming client has id, date, name, regn, active attributes).
I know it can be done, but i don't know if this goes against what you are aiming for with this project.
Tell me what you think.
Thanks.
The text was updated successfully, but these errors were encountered: