At 09:42 7/6/2002 -0500, you wrote:

> This one it wrong. You only need (can have) 
> cmr->field-type if the cmr-field is multi-valued.
> I think this is another lame place in the spec, as 
> I can look up the field type using reflection, but 
> it is required.  Just remove the line and it 
> should start working.

  I did it and now it is being deployed without
errors.
  But when I try to make the relationships I get a
exception. I can insert the data without problems,
then I do this code to make the relationship.

    Object ref = jndiContext.lookup("Order");
    OrderHome order_home = (OrderHome)
PortableRemoteObject.narrow (ref, OrderHome.class);
    Order o = order_home.findByPrimaryKey(new
OrderPK(new Integer(1)));

    ref = jndiContext.lookup("Item");
    ItemHome item_home = (ItemHome)
PortableRemoteObject.narrow (ref, ItemHome.class);
    Item i = item_home.findByPrimaryKey(new ItemPK(new
Integer(1)));

    On this point everthing is ok. I get the objects
to the both objects and they are valid. Then to make
the relationship I can do 2 things : or I use the
setOrder method of Item or I use the setItems method
of Order. Both fail :

    Collection c = o.getItems();  // the exception
happen here
    c.add(i);
    o.setItems(c);

  On this case the exception is :

  "java.lang.reflect.UndeclaredThrowableException"

  The other way could be :

    i.setOrder(o);

  And the error is :

java.rmi.ServerException: RemoteException occurred in
server thread; nested exception is: 
        java.rmi.ServerException: null
Embedded Exception
$Proxy102; nested exception is: 
        javax.ejb.EJBException: null
Embedded Exception
$Proxy102

  What is the problem now ?

  Andre S.

__________________________________________________
Do You Yahoo!?
Yahoo! - Official partner of 2002 FIFA World Cup
http://fifaworldcup.yahoo.com

_______________________________________________________________

Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas - 
http://devcon.sprintpcs.com/adp/index.cfm?source=osdntextlink

_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to