0 Replies Latest reply on Nov 5, 2003 4:12 PM by fsfxi44

    No such entity - Not Hitting DB?

    fsfxi44 Newbie

      I am receiving the follwing error: javax.ejb.ObjectNotFoundException: No such entity

      When making a call to to my findByPrimaryKey(281407) method.

      Now 281407 does actually exist in the database. I ran a profile/trace on the database and see the JBOSS container make a connection
      to the database but I never see the SQL generated by the findByPrimaryKey method in the database profile/trace.


      here is the trace from log4j:

      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.LogInterceptor] Start method=findByPrimaryKey
      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.TxInterceptorCMT] Current transaction in MI is null
      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.TxInterceptorCMT] TX_REQUIRED for findByPrimaryKey
      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.TxInterceptorCMT] Thread came in with tx null
      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.TxInterceptorCMT] Starting new tx TransactionImpl:XidImpl [FormatId=257, GlobalId=dh6s8x21//45, BranchQual=]
      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.EntityInstancePool] Get instance org.jboss.ejb.plugins.EntityInstancePool@753c22#0#class com.fxi.common.persistence.SiteEJB
      2003-11-05 15:33:14,953 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCFindByPrimaryKeyQuery.Site#findByPrimaryKey] Executing SQL: SELECT siteId FROM SITE WHERE siteId=?
      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.cmp.jdbc.JDBCFindByPrimaryKeyQuery.Site#findByPrimaryKey] Set parameter: index=1, jdbcType=INTEGER, value=218270
      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.TxInterceptorCMT] TxInterceptorCMT: In finally
      2003-11-05 15:33:14,953 TRACE [org.jboss.ejb.plugins.LogInterceptor] End method=findByPrimaryKey


      Any help would be greatly appreciated.

      BTW can someone tell me why there would be a
      Set parameter action AFTER Executing SQL action......am I missing something there......


      Thanks,