It looks like the real culprit is bug
https://bugs.eclipse.org/bugs/show_bug.cgi?id=317448 - JPA
forward mapper fails to create join table
It seems that table creation on MySQL always requires field size for
LONGBLOB.
That should be fixed in MySQLPlatform.buildFieldTypes method:
the FieldTypeDefinitions for LONGBLOB (what about LONGTEXT?) should be
changed to allow size, and should specify default size (what would be a
reasonable value?)
from:
fieldTypeMapping.put(byte[].class, new
FieldTypeDefinition("LONGBLOB", false));
to:
fieldTypeMapping.put(byte[].class, new
FieldTypeDefinition("LONGBLOB", 16));
The latter would indicate that the size is required, and if not
provided then the default value will be used.
On 15/07/2010 3:37 PM, Goerler, Adrian wrote:
Hi Andrei, all,
The patch uses a descriptor
customizer in order to specify the column definittion for the binary
column in a database-specific way.
I have tested this on MySQL
and Oracle. Likely, it needs to be extended to cover more database
dialects.
Could you please have a look?
Regards,
Adrian
Hi Adrian,
Starting yesterday (Wed. July 14th) I am getting lots of errors (146
errors 4 failures) when I run test-wdf on Oracle, yet official build
results are clean.
It seems all the errors are the same - table doesn't exist. It look
like:
Internal Exception: java.sql.SQLSyntaxErrorException: ORA-00942: table
or view does not exist Error Code: 942 Call: SELECT t1.ID, t1.LASTNAME,
t1.FIRSTNAME, t1.SALARY, t1.SAMPLE_ACCOUNT, t1.PROFILE_GUID,
t1.DEPARTMENT, t1.COSTCENTER, t1.CUBICLE_FLOOR, t1.CUBICLE_PLACE,
t1.BROKERAGE_ACCOUNT, t1.EMP_START, t1.EMP_END FROM TMP_EMP_BICYCLE t0,
TMP_EMP t1 WHERE ((t0.BICYCLE_ID = ?) AND (t1.ID = t0.EMPLOYEE_ID))
bind => [7] Query: ReadAllQuery(name="riders"
referenceClass=Employee sql="SELECT t1.ID, t1.LASTNAME, t1.FIRSTNAME,
t1.SALARY, t1.SAMPLE_ACCOUNT, t1.PROFILE_GUID, t1.DEPARTMENT,
t1.COSTCENTER, t1.CUBICLE_FLOOR, t1.CUBICLE_PLACE,
t1.BROKERAGE_ACCOUNT, t1.EMP_START, t1.EMP_END FROM TMP_EMP_BICYCLE t0,
TMP_EMP t1 WHERE ((t0.BICYCLE_ID = ?) AND (t1.ID = t0.EMPLOYEE_ID))")
Local Exception Stack:
Exception [EclipseLink-4002] (Eclipse Persistence Services -
2.2.0.qualifier): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLSyntaxErrorException: ORA-00942: table
or view does not exist
or
Exception [EclipseLink-4002] (Eclipse Persistence Services -
2.2.0.qualifier): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLSyntaxErrorException: ORA-00942: table
or view does not exist Error Code: 942 Call: INSERT INTO TMP_EMP (ID,
LASTNAME, FIRSTNAME, SALARY, SAMPLE_ACCOUNT, PROFILE_GUID, DEPARTMENT,
COSTCENTER, CUBICLE_FLOOR, CUBICLE_PLACE, BROKERAGE_ACCOUNT, EMP_START,
EMP_END) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) bind =>
[1234, Mouse, Mighty, null, null, null, null, null, null, null, null,
null, null] Query:
InsertObjectQuery(org.eclipse.persistence.testing.models.wdf.jpa1.employee.Employee@1de6ff8)
javax.persistence.RollbackException: Exception [EclipseLink-4002]
(Eclipse Persistence Services - 2.2.0.qualifier):
org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: java.sql.SQLSyntaxErrorException: ORA-00942: table
or view does not exist
Any idea what that might be?
Thanks,
Andrei
eclipselink.jpa.wdf.test\reports\*.* is attached
On 14/07/2010 7:30 AM, Goerler, Adrian wrote:
Hi,
reviewed by Kevin and checked
in in trunk at # 7814,
-Adrian
Hi Adrian,
The patch for this workaround are fine for me.
Thanks,
Kevin
On 13/07/2010 12:51 PM, Goerler, Adrian wrote:
Hi Kevin,
I am proposing a workaround for the failing WDF tests
until the issue 317448 is solved.
The workaround uses a columnDefinition and hence will
work on MySQL only, I am afraid.
Could you please have a look?
Thanks,
Adrian
SAP AG
Dietmar-Hopp-Allee
16, 69190 Walldorf, Germany
Sitz der
Gesellschaft/Registered Office: Walldorf, Germany
Vorstand/SAP
Executive Board: Henning Kagermann (Sprecher/CEO), Léo Apotheker
(stellvertretender Sprecher/Deputy CEO), Werner Brandt, Claus Heinrich,
Gerhard Oswald, John Schwarz, Peter Zencke
Vorsitzender des
Aufsichtsrats/Chairperson of the SAP Supervisory Board: Hasso Plattner
Registergericht/Commercial
Register Mannheim No HRB 350269
_______________________________________________
eclipselink-dev mailing list
eclipselink-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-dev
_______________________________________________
eclipselink-dev mailing list
eclipselink-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-dev
|