db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mamta Satoor" <msat...@gmail.com>
Subject Re: Global Temp tables
Date Fri, 23 Feb 2007 17:51:06 GMT
Lance, I am sure you have already checked following but wanted to throw them
out anyways
1)Is the temporary table getting referenced by the same connection that
created it?
2)Does your particular scenario work under embedded Derby?

 Also, once the connection that created the global table closes, the global
table cease to exist.

I think it will be worth checking the script under embedded Derby to rule
out Network Server as the culprit.

Mamta


On 2/23/07, Lance J. Andersen <Lance.Andersen@sun.com> wrote:
>
> Does anyone have an idea as to why the gobal table cannot be found.
>
> Here is the trace output.
>
> Regards
> lance
>
> [TopLink Fine]:
>
> ClientSession(12549034)--Connection(16309502)--Thread(Thread[AWT-EventQueue-0,6,main])--DECLARE
> GLOBAL TEMPORARY TABLE session.TL_CMP3_EMPLOYEE (EMP_ID INTEGER NOT
> NULL, PAY_SCALE VARCHAR(255), ROOM_NUM INTEGER, F_NAME VARCHAR(255),
> STATUS INTEGER, L_NAME VARCHAR(255), VERSION INTEGER, ADDR_ID INTEGER,
> MANAGER_EMP_ID INTEGER, START_DATE DATE, END_DATE DATE, DEPT_ID INTEGER,
> PRIMARY KEY (EMP_ID)) ON COMMIT DELETE ROWS NOT LOGGED
> [TopLink Fine]:
>
> ClientSession(12549034)--Connection(16309502)--Thread(Thread[AWT-EventQueue-0,6,main])--DECLARE
> GLOBAL TEMPORARY TABLE session.TL_CMP3_SALARY (EMP_ID INTEGER NOT NULL,
> SALARY INTEGER, PRIMARY KEY (EMP_ID)) ON COMMIT DELETE ROWS NOT LOGGED
> [TopLink Fine]:
>
> ClientSession(12549034)--Connection(16309502)--Thread(Thread[AWT-EventQueue-0,6,main])--INSERT
> INTO session.TL_CMP3_EMPLOYEE (EMP_ID, ROOM_NUM, VERSION) SELECT
> t0.EMP_ID, t1.SALARY, (t0.VERSION + 1) FROM CMP3_EMPLOYEE t0,
> CMP3_SALARY t1 WHERE ((t0.F_NAME = 'testUpdateUsingTempStorage') AND
> (t1.EMP_ID = t0.EMP_ID))
> [TopLink Fine]:
>
> ClientSession(12549034)--Connection(16309502)--Thread(Thread[AWT-EventQueue-0,6,main])--DELETE
> FROM session.TL_CMP3_EMPLOYEE
> [TopLink Fine]:
>
> ClientSession(12549034)--Connection(16309502)--Thread(Thread[AWT-EventQueue-0,6,main])--DELETE
> FROM session.TL_CMP3_SALARY
> [TopLink Warning]:
> UnitOfWork(31852201)--Thread(Thread[AWT-EventQueue-0,6,main])--Local
> Exception Stack:
> Exception [TOPLINK-4002] (Oracle ${_EssentialsProductName} -
> ${_EssentialsProductVersion} (Build 070220Dev)):
> oracle.toplink.essentials.exceptions.DatabaseException
> Internal Exception: org.apache.derby.client.am.SqlException: Table
> 'SESSION.TL_CMP3_EMPLOYEE' does not exist.Error Code: -1
> Call:INSERT INTO session.TL_CMP3_EMPLOYEE (EMP_ID, ROOM_NUM, VERSION)
> SELECT t0.EMP_ID, t1.SALARY, (t0.VERSION + 1) FROM CMP3_EMPLOYEE t0,
> CMP3_SALARY t1 WHERE ((t0.F_NAME = 'testUpdateUsingTempStorage') AND
> (t1.EMP_ID = t0.EMP_ID))
> Query:UpdateAllQuery()
>

Mime
View raw message