My Oracle Support Banner

WLS 10.3: Character Data type in JPA Entities treated as Integer and throwing Data Type Mismatch Error. (Doc ID 1159084.1)

Last updated on JANUARY 04, 2019

Applies to:

Oracle Weblogic Server - Version: 10.3 and later   [Release: and later ]
Information in this document applies to any platform.


In Open JPA 'Character' is treated as Integer by EJB 3.0 implementation and throws Data Type mismatch error as below:

Exception in thread "main" javax.ejb.EJBException: EJB Exception: ; nested exception is:
<openjpa-1.1.1-SNAPSHOT-r422266:891341 fatal user error> org.apache.openjpa.persistence.ArgumentException: "" declares a column that is not compatible with the expected type "integer". Column details:
Type: varchar
Size: 1
Default: null
Not Null: false

at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.unwrapRemoteException(
at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(
at $Proxy0.addPerson(Unknown Source)
at com.tekelec.gps.ias.nsp.sample.ejb3.tests.integration.TestPersonService.addPersonwithCharDataType(
at com.tekelec.gps.ias.nsp.sample.ejb3.tests.integration.TestPersonService.main(
Caused by: <openjpa-1.1.1-SNAPSHOT-r422266:891341 fatal user error> org.apache.openjpa.persistence.ArgumentException:




To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!

In this Document

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.