1 Reply Latest reply on Oct 3, 2003 7:35 PM by eric g

    EJBQL mapping error

    David Norwood Newbie

      I'm using JBoss 3.2x and DB2 7.1, and keep getting errors whenever I attempt to execute a finder, as the SQL produced is always 'SELECT FROM {tablename}...' Apparently the 'SELECT OBJECT(o)' isn't getting translated.

      Upon startup, the L4J output shows what is below. Any ideas as to what's going on?

      2003-08-27 13:07:33,194 INFO [org.jboss.ejb.EntityContainer] Starting
      2003-08-27 13:07:33,314 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.dsntab1] Initializing CMP plugin for dsntab1
      2003-08-27 13:07:33,324 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.dsntab1] Loading standardjbosscmp-jdbc.xml : file:/C:/DOC/jboss/server/default/conf/standardjbosscmp-jdbc.xml
      2003-08-27 13:07:33,834 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.dsntab1] jar:file:/C:/DOC/jboss/server/default/tmp/deploy/tmp13431oow.ear-contents/oow-ejb.jar!/META-INF/jbosscmp-jdbc.xml found. Overriding defaults
      2003-08-27 13:07:34,025 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.dsntab1] Insert Entity SQL: INSERT INTO HZAZDB3.dsntab1 (DENAME, CDVALUE, CDDESC, RELMDFLG, CMNTFLAG, CREATEBY, CREATEDT, LASTUPBY, LASTUPDT, TIMESUPD) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
      2003-08-27 13:07:34,035 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.dsntab1] Entity Exists SQL: SELECT COUNT(*) FROM HZAZDB3.dsntab1 WHERE
      2003-08-27 13:07:34,045 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCCommandFactory.dsntab1] entity-command: [commandName=default,commandClass=class org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand,attributes={}]
      2003-08-27 13:07:34,045 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCRemoveEntityCommand.dsntab1] Remove SQL: DELETE FROM HZAZDB3.dsntab1 WHERE
      2003-08-27 13:07:48,149 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCStartCommand.dsntab1] Table not create as requested: HZAZDB3.dsntab1
      2003-08-27 13:07:48,149 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCFindByPrimaryKeyQuery.dsntab1.findByPrimaryKey] SQL: SELECT FROM HZAZDB3.dsntab1 WHERE
      2003-08-27 13:07:48,149 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCQueryManager.dsntab1] Added findByPrimaryKey query command for local home interface
      2003-08-27 13:07:48,159 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByLastupdt] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.lastupdt = ?1
      2003-08-27 13:07:48,159 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByLastupdt] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.LASTUPDT = ?
      2003-08-27 13:07:48,169 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCreatedt] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.createdt = ?1
      2003-08-27 13:07:48,169 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCreatedt] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.CREATEDT = ?
      2003-08-27 13:07:48,179 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findAll] EJB-QL: SELECT OBJECT(o) FROM dsntab1 o
      2003-08-27 13:07:48,179 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findAll] SQL: SELECT FROM HZAZDB3.dsntab1 t0_o
      2003-08-27 13:07:48,179 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCreateby] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.createby = ?1
      2003-08-27 13:07:48,189 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCreateby] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.CREATEBY = ?
      2003-08-27 13:07:48,189 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByTimesupd] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.timesupd = ?1
      2003-08-27 13:07:48,199 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByTimesupd] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.TIMESUPD = ?
      2003-08-27 13:07:48,199 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByLastupby] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.lastupby = ?1
      2003-08-27 13:07:48,209 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByLastupby] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.LASTUPBY = ?
      2003-08-27 13:07:48,209 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByDename] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.dename = ?1
      2003-08-27 13:07:48,219 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByDename] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.DENAME = ?
      2003-08-27 13:07:48,219 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCdvalue] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.cdvalue = ?1
      2003-08-27 13:07:48,229 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCdvalue] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.CDVALUE = ?
      2003-08-27 13:07:48,229 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCmntflag] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.cmntflag = ?1
      2003-08-27 13:07:48,239 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCmntflag] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.CMNTFLAG = ?
      2003-08-27 13:07:48,239 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCddesc] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.cddesc = ?1
      2003-08-27 13:07:48,249 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByCddesc] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.CDDESC = ?
      2003-08-27 13:07:48,249 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByRelmdflg] EJB-QL: SELECT DISTINCT OBJECT(o) FROM dsntab1 o WHERE o.relmdflg = ?1
      2003-08-27 13:07:48,259 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCEJBQLQuery.dsntab1.findByRelmdflg] SQL: SELECT DISTINCT FROM HZAZDB3.dsntab1 t0_o WHERE t0_o.RELMDFLG = ?