I have put in about 3 days worth of struggling to use Xdoclet. Need basic beginner help.

I can get my Entity Bean to launch and I can get a handle to the home interface by using the generated Util Class. But when I try to call my create method I get the following error.

javax.ejb.CreateException: Could not create entity:java.sql.SQLException: Column not found: DESC in statement [INSERT INTO ROLES (name, desc, comments) VALUES ('Kevin', 'All', 'Everyone')] at org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.insertEntity(JDBCCreateEntityCommand.java:199

My Base Bean is as follows. Any pointer and help as to why I'm getting this error would be greatly appreciated and have much impact on how much more time I put into learning xdoclet.
Thanks...


package test.ejb;

import test.interfaces.*;
import javax.ejb.EntityBean;
import javax.ejb.CreateException;


/** * @ejb:bean * name="Roles" * type="CMP" * view-type="local" * local-jndi-name="test.interfaces.RolesLocalHome" * schema="Roles" * * @ejb.util generate="physical" * @ejb.finder signature="java.util.Collection findAll()" * @ejb:value-object name="Roles" match="*" * */ public abstract class RolesBean implements EntityBean {

   /**
    * @ejb.pk-field
    * @ejb.persistent-field
    * @ejb.persistence
    *      column-name="NAME"
    *      jdbc-type="VARCHAR"
    *      sql-type="varchar(255)"
    * @ejb.interface-method
    */
   public abstract String getName();

   public abstract void setName(String name);
   /**
    * @ejb:interface-method
    * @ejb:persistent-field
    * @ejb.persistence
    *      column-name="desc"
    *      jdbc-type="VARCHAR"
    *      sql-type="varchar(255)"
    *  @jboss.column-name name="desc"
    *  @jboss.sql-type type = "varchar(255)"
    *  @jboss.jdbc-type type = "VARCHAR"
    */
   public abstract String getDesc();

   public abstract void setDesc(String desc);
   /**
    * @ejb:interface-method
    * @ejb:persistent-field
    * @ejb.persistence
    *      column-name="comments"
    *      jdbc-type="VARCHAR"
    *      sql-type="varchar(255)"
    *  @jboss.column-name name="comments"
    *  @jboss.sql-type type = "varchar(255)"
    *  @jboss.jdbc-type type = "VARCHAR"
    */
   public abstract String getComments();

public abstract void setComments(String comments);

   /**
    * @ejb.create-method
    */
   public RolesPK ejbCreate(String name,String desc,String comments )
       throws CreateException
   {
       setName(name);
       setDesc(desc);
       setComments(comments);
       return null;
   }
   public void ejbPostCreate(String name,String desc, String comments  )
       throws CreateException {}
}

_________________________________________________________________
Get McAfee virus scanning and cleaning of incoming attachments. Get Hotmail Extra Storage! http://join.msn.com/?PAGE=features/es




-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user

Reply via email to