Issue Details (XML | Word | Printable)

Key: GLASSFISH-18907
Type: Bug Bug
Status: Resolved Resolved
Resolution: Won't Fix
Priority: Blocker Blocker
Assignee: Mitesh Meswani
Reporter: sredelin
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
glassfish

Missing schema name in generated SQL using glassfish 3.1.2 (build 23)

Created: 16/Jul/12 09:51 AM   Updated: 26/Jul/12 05:55 AM   Resolved: 26/Jul/12 05:55 AM
Component/s: cmp
Affects Version/s: 3.1.2_b23
Fix Version/s: None

Time Tracking:
Not Specified

Environment:

local: Windows XP with GF 3.1.2 (build 23) + JDK 1.7
server: Oracle Database 10.2.05


Tags:
Participants: marina vatkina, Mitesh Meswani and sredelin


 Description  « Hide

I've got a big Problem with the usage of glassfish and don't know if it's a bug or a configuration mistake.
For our business software we use actually the weblogic application server.
We want to switch to glassfish V3.
Now I check local for ToDos.

My JNDI - DataSource Connection has been established and together with the correct *.dbschema-File I'am able to deploy.
All SessionBeans with connection to the database are working fine.
My Problem are the EntityBeans.

From my point of view the problem ist, that my DBUser is different to the Schema-User.
The result of performing a function ist this stack trace:

[#|2012-07-16T09:36:47.117+0200|WARNING|glassfish3.1.2|javax.enterprise.system.container.ejb.entity.finder|_ThreadID=79;_ThreadName=Thread-2;|JDO74004: Bean 'InfoUpdateBean' Methode ejbFindByPrimaryKey:
com.sun.jdo.api.persistence.support.JDODataStoreException: JDO76400: JDBC-SQLException beim Ausführen der SQL-Anweisung:
SQL-Anweisung<select t0."AUTO_KEY", t0."FIKT_LIEF_NR", t0."INFOTEXT_NR", t0."ANZEIGEN_KZ", t0."GELADEN_AM", t0."LETZTE_AKTUALISIERUNG", t0."BENUTZER_ID" from "LIS_ZUORDNUNG" t0 where t0."AUTO_KEY" = ?> mit Eingabewerten:java.lang.Long:1159049.
Weitere Informationen finden Sie in der SQLException.
NestedException: java.sql.SQLSyntaxErrorException: ORA-00942: table or view does not exist

So the Problem is, that the table "LIS_ZUORDNUNG" doesn't exist at the point of view from the current User.
The SQL has to include a pretended schema name like NDA."LIS_ZUORDNUNG".
Then the SQL works fine inside the SQL Developer...



No work has yet been logged on this issue.