[
https://issues.apache.org/jira/browse/METAMODEL-157?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Kasper Sørensen resolved METAMODEL-157.
---------------------------------------
Resolution: Fixed
Assignee: Kasper Sørensen
Fix Version/s: 4.4.0
> Jdbc delete uses Statement.setObject(...) which isn't always supported
> ----------------------------------------------------------------------
>
> Key: METAMODEL-157
> URL: https://issues.apache.org/jira/browse/METAMODEL-157
> Project: Apache MetaModel
> Issue Type: Bug
> Environment: PostgreSQL.
> MetaModel-jdbc module.
> Reporter: Kasper Sørensen
> Assignee: Kasper Sørensen
> Labels: starter
> Fix For: 4.4.0
>
>
> I am trying to express a delete criteria using a date as the criteria for
> deleting. Like this for example:
> {code}
> DELETE FROM table WHERE date_created = '2015-07-01'
> {code}
> The problem I run into is that my database driver (PostgreSQL) is complaining
> about the Statement.setObject(...) call we are doing in JdbcDeleteBuilder
> line 73. I am passing in a java.util.Date and apparently it's not able to
> properly handle it.
> I notice that in e.g. JdbcUpdateBuilder (line 75) we use
> JdbcUtils.setStatementValue(...). I imagine that doing this instead provides
> a better call into the JDBC API and thus will get me out of my current JDBC
> driver exception.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)