Thanks to those who responded, but we've resolved our issue.  For the
curious:

Situation:

CMP Entity Bean with attributes that have a primitive type, e.g.:
  double foo;

The table the entity bean was mapped to contained rows which did
not have a value for the "foo" column.

When retrieving these rows, Weblogic 4.51 did not throw any exceptions,
and a getFoo() would return 0.0.  I don't know if this was the default
value that foo initialized to, or if it was assigned by the CMP routines.

Resolution.

We resolved the problem by using the primitive wrapper classes.
Fortunately,
Weblogic's default CMP handles them just fine.  When using:
  Double foo;

The call to getFoo() returned null for the rows that did not have this
value.

I don't know if this behavior is even addressed by the spec, so I can
only comment as to what Weblogic did.

-tb

> -----Original Message-----
> From: Biske, Todd
> Sent: Monday, August 21, 2000 11:26 AM
> To:   'EJB Interest'
> Subject:      Container mapping to null columns
>
> We've just run across a data integrity problem where some numeric columns
> (i.e. integers or floats) in the database do not have values.  How does a
> CMP entity bean handle this situation?  What will be assigned to the EJB
> attributes that are mapped to these columns?
>
> Thanks-
> -tb
>
> --------------------------------------------------------------
> Todd Biske                               [EMAIL PROTECTED]
> Java Mentoring Team
> A.G. Edwards & Sons, Inc.
>


***************************************************************************************
WARNING:  All e-mail sent to and from this address will be received or
otherwise recorded by the A.G. Edwards corporate e-mail system and is
subject to archival, monitoring or review by, and/or disclosure to,
someone other than the recipient.
***************************************************************************************

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to