AppletTalk.com Forum Index AppletTalk.com
Java discussions newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problem with a simple CMP bean while working on JBoss

 
Post new topic   Reply to topic    AppletTalk.com Forum Index -> Java Help
View previous topic :: View next topic  
Author Message
Subra
Guest





PostPosted: Tue Sep 21, 2004 10:22 am    Post subject: Problem with a simple CMP bean while working on JBoss Reply with quote



Problem with a simple CMP bean while working on JBoss

CLIENT : EmployeeSalInsertClient.java
CMP Jar: emp
------------------------------------------------
Database : MS SQL SERVER
Table Name is : emp
Column names:
eno - int
ename - varchar(30)
esal - float

It is a simple ejb.........
able to insert the records into the database.............
unable to find records..................

The error is given below

C:javajava -classpath

..;D:jboss-3.2.4serverdefaultlibjboss-j2ee.jar;D:jboss-3.2.4serv

erdefaultlibjbossall-client.jar;D:jboss-3.2.4serverdefaultlibjnet.jar;
EmployeeSalInsertClient
Exception in thread "main" javax.ejb.FinderException: Unknown query:
public
abstract emp.Employee
emp.EmployeeHome.findByPrimaryKey(java.lang.Integer)
throws java.rmi.RemoteException,javax.ejb.FinderException
at

sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.jav
a:245)
at

sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:220)
at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:122)
at
org.jboss.invocation.jrmp.server.JRMPInvoker_Stub.invoke(Unknown
Source)
at

org.jboss.invocation.jrmp.interfaces.JRMPInvokerProxy.invoke(JRMPInvokerProxy.java:
135)
at

org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:96)
at

org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:46)
at

org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:53)
at
org.jboss.proxy.ejb.HomeInterceptor.invoke(HomeInterceptor.java:173)
at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:85)
at $Proxy0.findByPrimaryKey(Unknown Source)
at
EmployeeSalInsertClient.main(EmployeeSalInssimertClient.java:34)
Back to top
Tomer Ben-David
Guest





PostPosted: Thu Sep 23, 2004 4:14 pm    Post subject: Re: Problem with a simple CMP bean while working on JBoss Reply with quote



[email]s_vaddi (AT) yahoo (DOT) com[/email] (Subra) wrote in message news:<f4283ea5.0409210222.45e2e7b5 (AT) posting (DOT) google.com>...
Quote:
Problem with a simple CMP bean while working on JBoss

CLIENT : EmployeeSalInsertClient.java
CMP Jar: emp
------------------------------------------------
Database : MS SQL SERVER
Table Name is : emp
Column names:
eno - int
ename - varchar(30)
esal - float

It is a simple ejb.........
able to insert the records into the database.............
unable to find records..................

The error is given below

C:javajava -classpath

.;D:jboss-3.2.4serverdefaultlibjboss-j2ee.jar;D:jboss-3.2.4serv

erdefaultlibjbossall-client.jar;D:jboss-3.2.4serverdefaultlibjnet.jar;
EmployeeSalInsertClient
Exception in thread "main" javax.ejb.FinderException: Unknown query:
public
abstract emp.Employee
emp.EmployeeHome.findByPrimaryKey(java.lang.Integer)
throws java.rmi.RemoteException,javax.ejb.FinderException
at

sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.jav
a:245)
at

sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:220)
at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:122)
at
org.jboss.invocation.jrmp.server.JRMPInvoker_Stub.invoke(Unknown
Source)
at

org.jboss.invocation.jrmp.interfaces.JRMPInvokerProxy.invoke(JRMPInvokerProxy.java:
135)
at

org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:96)
at

org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:46)
at

org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:53)
at
org.jboss.proxy.ejb.HomeInterceptor.invoke(HomeInterceptor.java:173)
at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:85)
at $Proxy0.findByPrimaryKey(Unknown Source)
at
EmployeeSalInsertClient.main(EmployeeSalInssimertClient.java:34)


do you have a findByPrimaryKey method in your bean home interface ?

Back to top
Display posts from previous:   
Post new topic   Reply to topic    AppletTalk.com Forum Index -> Java Help All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.