Hello Jon :)

Don't use long for your id, use Long instead. Else you will have this error each time you have null in database for the id field.

/Lennart

torsdagen den 17 oktober 2002 kl 12.31 skrev Jon Haugsand:

Running JBoss 3.0.2 with a fairly trivial entity bean:

     /**
      * @ejb:interface-method view-type="both"
      * @ejb:persistent-field
      */
    public abstract long getId();

     /**
      */
    public abstract void setId( long id );

    /**
     * @ejb:interface-method
     */
    public abstract void setNavn(String v);
    /**
     * @ejb:interface-method
     * @ejb:persistent-field
     * @ejb:pk-field
     */
    public abstract String getNavn();


Sometimes the findByPrimaryKey returns NullPointerException.  Has
anyone experimented something similarly?

--
  Jon Haugsand, <[EMAIL PROTECTED]>
  Norges Bank, <http://www.norges-bank.no>



-------------------------------------------------------
This sf.net email is sponsored by: viaVerio will pay you up to
$1,000 for every account that you consolidate with us.
http://ad.doubleclick.net/clk;4749864;7604308;v?
http://www.viaverio.com/consolidator/osdn.cfm
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


-------------------------------------------------------
This sf.net email is sponsored by: viaVerio will pay you up to
$1,000 for every account that you consolidate with us.
http://ad.doubleclick.net/clk;4749864;7604308;v?
http://www.viaverio.com/consolidator/osdn.cfm
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to