cancel
Showing results for 
Search instead for 
Did you mean: 

Error in wrting Object to Database

former_member188321
Contributor
0 Kudos

Hi,

When I go to "persistent.xml-><EJBname>->cmr-field-><fieldName>", on right hand side, in additional information section it shows "ERROR:

The class of this dependent value has no public fields. Because of this it can only be mapped to a single column".

That field is an object of some other class. So, whereever I have any column storing object of some class, I have the same message.

Due to his, its giving deployment error.

"Cannot obtain an appropriate JDBC type for class com.bea.medrec.entities.RecordLocal. To store the field with this class in the database, the class must implement java.io.Serializable."

Please suggest what could be the solution.

Thanks!

Accepted Solutions (0)

Answers (1)

Answers (1)

kishorg
Advisor
Advisor
0 Kudos

Hi Dhamandheep ,

which is the data type of the field u have created?.

is it your own class type (Custom class).

if u r using your own class as data type , u have to implement java.io.Serializable to that class.

regards

Kishor Gopinathan

former_member188321
Contributor
0 Kudos

Hi,

I am using a custom Class.

I cannot implement java.io.Serializable to that class.

Because, the error is for <EJB>Local interface.

It says that the class must implement java.io.Serializable. But an interface cannot.

Now, I want to write through CMP beans. But one of the field of the Bean is an Object of some other class. There it is giving problem.