4 Replies Latest reply on May 20, 2002 7:42 PM by matt

    Deployment of many->1 CMP relationship

    matt Newbie

      (Dont knowwhat happened on the last posting??
      but it left the title and the contents of the
      message out.)

      I have implemented a unidirectional many-to-one CMP,CRM,
      EntityBean and am not sure what I am doing wrong.

      I have followed the Oreilly EJB book 3rd edition and the
      jboss CMP2.0 doco.

      I have deployed under JBOSS3.0RC2

      I thave attached the source, xml files and a capture from the server.log

      A small snipit from the log is as follows:

      2002-05-20 19:27:21,297 DEBUG [org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.MLBPlayerBean] Loading standardjbosscmp-jdbc.xml : file:/usr/local/jboss-3.0.0RC2_tomcat-4.0.3/server/default/conf/standardjbosscmp-jdbc.xml
      2002-05-20 19:27:21,554 ERROR [org.jboss.ejb.EntityContainer] Exception in service lifecyle operation: create
      org.jboss.deployment.DeploymentException: Atleast one role of a foreign-key mapped relationship must have key fields: ejb-relation-name=player-team
      at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCRelationMetaData.(JDBCRelationMetaData.java:316)
      at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCApplicationMetaData.(JDBCApplicationMetaData.java:325)
      at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCXmlFileLoader.load(JDBCXmlFileLoader.java:67)



      Some help would be appreciated.
      Thanks matt.