You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openjpa.apache.org by "David Wisneski (JIRA)" <ji...@apache.org> on 2006/08/17 01:37:13 UTC
[jira] Created: (OPENJPA-23) -418 sqlexception using DB2 and EJB QL
with SQRT or MOD
-418 sqlexception using DB2 and EJB QL with SQRT or MOD
-------------------------------------------------------
Key: OPENJPA-23
URL: http://issues.apache.org/jira/browse/OPENJPA-23
Project: OpenJPA
Issue Type: Bug
Reporter: David Wisneski
generated SQL is missing CAST function to indicate type of ?
EJB QL : select e from EmpBean e where mod(e.empid,5)=0
DB2 SQL error: SQLCODE: -418, SQLSTATE: 42610, SQLERRMC: null {prepstmnt 1046232668
SELECT t0.empid, t0.bonus, t1.deptno, t1.budget, t1.name, t0.execLevel, t0.hireDate, t0.hireTime, t0.hireTimestamp,
t0.home, t0.isManager, t0.name, t0.salary, t0.work FROM EmpBean t0 LEFT OUTER JOIN DeptBean t1 ON t0.dept_deptno = t1.deptno
WHERE (MOD(t0.empid, ?) = ?)
db2 sql compiler is not able to resolve type of expression (MOD(t0.empid, ?) = ?. This expression should be
MOD(t0.empid, cast((?) as integer) ) = ?. or
MOD(t0.empid, 5) = 0
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] Resolved: (OPENJPA-23) -418 sqlexception using DB2 and EJB
QL with SQRT or MOD
Posted by "Marc Prud'hommeaux (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENJPA-23?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marc Prud'hommeaux resolved OPENJPA-23.
---------------------------------------
Resolution: Fixed
Assignee: Marc Prud'hommeaux
I am fairly certain this was fixed a while ago (around change #497715).
> -418 sqlexception using DB2 and EJB QL with SQRT or MOD
> -------------------------------------------------------
>
> Key: OPENJPA-23
> URL: https://issues.apache.org/jira/browse/OPENJPA-23
> Project: OpenJPA
> Issue Type: Bug
> Reporter: David Wisneski
> Assigned To: Marc Prud'hommeaux
> Fix For: 0.9.7
>
>
> generated SQL is missing CAST function to indicate type of ?
> EJB QL : select e from EmpBean e where mod(e.empid,5)=0
> DB2 SQL error: SQLCODE: -418, SQLSTATE: 42610, SQLERRMC: null {prepstmnt 1046232668
> SELECT t0.empid, t0.bonus, t1.deptno, t1.budget, t1.name, t0.execLevel, t0.hireDate, t0.hireTime, t0.hireTimestamp,
> t0.home, t0.isManager, t0.name, t0.salary, t0.work FROM EmpBean t0 LEFT OUTER JOIN DeptBean t1 ON t0.dept_deptno = t1.deptno
> WHERE (MOD(t0.empid, ?) = ?)
> db2 sql compiler is not able to resolve type of expression (MOD(t0.empid, ?) = ?. This expression should be
> MOD(t0.empid, cast((?) as integer) ) = ?. or
> MOD(t0.empid, 5) = 0
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OPENJPA-23) -418 sqlexception using DB2 and EJB QL
with SQRT or MOD
Posted by "Patrick Linskey (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENJPA-23?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Patrick Linskey updated OPENJPA-23:
-----------------------------------
Fix Version/s: 0.9.7
> -418 sqlexception using DB2 and EJB QL with SQRT or MOD
> -------------------------------------------------------
>
> Key: OPENJPA-23
> URL: https://issues.apache.org/jira/browse/OPENJPA-23
> Project: OpenJPA
> Issue Type: Bug
> Reporter: David Wisneski
> Fix For: 0.9.7
>
>
> generated SQL is missing CAST function to indicate type of ?
> EJB QL : select e from EmpBean e where mod(e.empid,5)=0
> DB2 SQL error: SQLCODE: -418, SQLSTATE: 42610, SQLERRMC: null {prepstmnt 1046232668
> SELECT t0.empid, t0.bonus, t1.deptno, t1.budget, t1.name, t0.execLevel, t0.hireDate, t0.hireTime, t0.hireTimestamp,
> t0.home, t0.isManager, t0.name, t0.salary, t0.work FROM EmpBean t0 LEFT OUTER JOIN DeptBean t1 ON t0.dept_deptno = t1.deptno
> WHERE (MOD(t0.empid, ?) = ?)
> db2 sql compiler is not able to resolve type of expression (MOD(t0.empid, ?) = ?. This expression should be
> MOD(t0.empid, cast((?) as integer) ) = ?. or
> MOD(t0.empid, 5) = 0
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.