Discussions

EJB programming & troubleshooting: findByPrimaryKey returning null-why

  1. findByPrimaryKey returning null-why (3 messages)

    USING EJB1.1 AND WEBLOGIC 5.1.0 , i have succesfully deployed an entity bean .i have data in my database but when i use finder methods it returns null .EVEN find/byPrimaryKey returns null
    Please suggest me a method
    regards
    ram
  2. findByPrimaryKey returning null-why[ Go to top ]

    difficult to say without the code
  3. findByPrimaryKey returning null-why[ Go to top ]

    i am also having the same problem,the primarykey class is having four parameters(i.e.,composite key)?Help pls.Thanx in advance.The bean was working perfectly in Weblogic4.5.1.

    Its giving runtime expection when the custom finder method is invoked from a stateless session bean:



    Fri Feb 02 16:29:07 GMT+05:30 2001:<E> <Adapter> Exception thrown by rmi server: [1334131264
    59340425S192.9.200.23:[80,80,7002,7002,80,-1]/262]
    java.lang.NullPointerException
            at weblogic.ejb.internal.LockManagerImpl.unlock(LockManagerImpl.java:160)
            at weblogic.ejb.internal.StatefulEJBCache.unbind(StatefulEJBCache.java:530)
            at weblogic.ejb.internal.StatefulEJBCache.releaseEJBContext(StatefulEJBCache.java:34
    3)
            at weblogic.ejb.internal.StatefulEJBHome.findOrCreateEJBObject(StatefulEJBHome.java:
    256)
            at weblogic.ejb.internal.StatefulEJBHome.findOrCreateEJBObject(StatefulEJBHome.java:
    242)
            at com.wsc.ecom.auction.WSCItemBMBeanHomeImpl.pkEnumToEnum(WSCItemBMBeanHomeImpl.jav
    a, Compiled Code)
            at com.wsc.ecom.auction.WSCItemBMBeanHomeImpl.findByKey(WSCItemBMBeanHomeImpl.java:8
    3)
            at com.wsc.ecom.auction.WSCItemBMBeanHomeImpl_WLSkel.invoke(WSCItemBMBeanHomeImpl_WL
    Skel.java:114)
            at weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerObjectAdapter.
    java, Compiled Code)
            at weblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicRequestHandler.jav
    a, Compiled Code)
            at weblogic.rmi.extensions.BasicRequestDispatcher.dispatch(BasicRequestDispatcher.ja
    va, Compiled Code)
            at weblogic.rmi.internal.ServerRequest.sendOneWay(ServerRequest.java, Compiled Code)

            at weblogic.rmi.internal.ServerRequest.sendReceive(ServerRequest.java, Compiled Code
    )
            at com.wsc.ecom.auction.WSCItemBMBeanHomeImpl_WLStub.findByKey(WSCItemBMBeanHomeImpl
    _WLStub.java:286)
            at com.wsc.ecom.auction.auctionmgr.WSCBidBean.displayBidDetails(WSCBidBean.java, Com
    piled Code)
            at com.wsc.ecom.auction.auctionmgr.WSCBidBeanEOImpl.displayBidDetails(WSCBidBeanEOIm
    pl.java:1264)
            at com.wsc.ecom.auction.auctionmgr.WSCBidBeanEOImpl_WLSkel.invoke(WSCBidBeanEOImpl_W
    LSkel.java:502)
            at weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerObjectAdapter.
    java, Compiled Code)
            at weblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicRequestHandler.jav
    a, Compiled Code)
            at weblogic.rmi.extensions.BasicRequestDispatcher.dispatch(BasicRequestDispatcher.ja
    va, Compiled Code)
            at weblogic.rmi.internal.ServerRequest.sendOneWay(ServerRequest.java, Compiled Code)

            at weblogic.rmi.internal.ServerRequest.sendReceive(ServerRequest.java, Compiled Code
    )
            at com.wsc.ecom.auction.auctionmgr.WSCBidBeanEOImpl_WLStub.displayBidDetails(WSCBidB
    eanEOImpl_WLStub.java:1460)
            at jsp_servlet._jsp._ecom._auction._display._wscbiddisplay._jspService(_wscbiddispla
    y.java, Compiled Code)
            at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
            at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java, Com
    piled Code)
            at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java, Com
    piled Code)
            at weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImpl.jav
    a, Compiled Code)
            at weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImpl.jav
    a, Compiled Code)
            at weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContextManag
    er.java, Compiled Code)
            at weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java, Compiled
    Code)
            at weblogic.socket.MuxableSocketHTTP.execute(MuxableSocketHTTP.java, Compiled Code)
            at weblogic.kernel.ExecuteThread.run(ExecuteThread.java, Compiled Code)
  4. Hi Vinod

    If you have found the answer to your problem could u please share it with us. I too am having the same problem with composite primary keys in Weblogic 5.1