Dropping Temp Tables
We are currently converting our student information system from Sybase to Oracle. My task is to convert our existing sql scripts. A number of them use temp tables and I have successfully got them to run except that I cannot drop the tables at the end of the script because they are still in use *[Error Code: 14452, SQL State: 72000] ORA-14452: attempt to create, alter or drop an index on temporary table already in use*. For example:
/* Oracle Version */
-- Select Cactus ID ------------------------------------------------------------
CREATE GLOBAL TEMPORARY TABLE tch1
(name Varchar(45), tid Int, CactusID Varchar(12))
ON COMMIT PRESERVE ROWS;
INSERT INTO tch1
SELECT
t.lastfirst,
t.id teacherid,
c.value
FROM
teachers t
INNER JOIN customvarchars c ON t.id = c.KeyNo
AND fieldno = 148;
-- Select Core Codes ---------------------------------------------------------------
CREATE GLOBAL TEMPORARY TABLE crs1
(name Varchar(45), cid Int, CactusCd Varchar(12))
ON COMMIT PRESERVE ROWS;
INSERT INTO crs1
SELECT
cs.course_name,
cs.id courseid,
c.value
FROM
Courses cs
INNER JOIN customvarchars c ON cs.id = c.KeyNo
AND fieldno = 146;
-- Put it all together ---------------------------------------------------------
SELECT
t.lastfirst AS Teacher,
ct.CactusID,
s.schoolid AS Sch#,
s.TermID,
c.course_number AS Crs#,
s.section_number AS Sec#,
c.course_name AS Course,
cr.CactusCd,
COUNT(*) AS Enroll
FROM
cc
INNER JOIN sections s ON cc.sectionid = s.id
INNER JOIN courses c ON s.course_number = c.course_number
LEFT JOIN crs1 cr ON c.id = cr.cid
INNER JOIN teachers t ON s.teacher = t.id
LEFT JOIN tch1 ct ON t.id = ct.tid
WHERE s.schoolid NOT IN (701,711)
GROUP BY
s.schoolid,
t.lastfirst,
ct.CactusID,
c.course_number,
s.section_number,
c.course_name,
cr.CactusCd,
s.TermID
ORDER BY
s.schoolid,
t.lastfirst,
ct.CactusID,
c.course_number,
s.section_number,
c.course_name,
cr.CactusCd,
s.TermID;
-- Drop Tables -----------------------
DROP TABLE tch1;
DROP TABLE crs1;
I have an Oracle PL/SQL reference guide at hand, but I don't see any mention of dropping the tables when completed. I'm also curious if I'm using the terminator (;) correctly. MS SQL Server and Sybase did not require one.
Thanks.
Christopher Soza wrote:
you need to issue a
COMMIT;
prior to issueing the drop table commands
COMMIT will not help since GTT is ON COMMIT PRESERVE ROWS:
Session 1:
SQL> CREATE GLOBAL TEMPORARY TABLE tch1
2 (name Varchar(45), tid Int, CactusID Varchar(12))
3 ON COMMIT PRESERVE ROWS;
Table created.
SQL> insert into tch1 values('A',1,'B');
1 row created.
SQL> commit;
Commit complete.
SQL> Session 2:
SQL> drop table tch1;
drop table tch1
ERROR at line 1:
ORA-14452: attempt to create, alter or drop an index on temporary table already
in use
SQL> SY.
Similar Messages
-
how to drop temp tables if i created with same name in different sessions
create table #temp(id int)
(with same in different sessions)In addition to Olaf's, if you create temp table in two different sessions, you will find the 2 #test in the TempDB.sys.tables.
CREATE TABLE #test (id int);
Either the different object_ids or the "same" names indicate they are
different temp tables. The same named local temp tables created in different sessions are traced with a 12 suffix in the tempdb.sys.tables. That's why when creating temp tables, maximum length can be of 116 characters only, while creating a
table, the maximum is 128.
The fragment referenced from the BOL
You can create local and global temporary tables. Local temporary tables are visible only in the current session; global temporary tables are visible to all sessions.
All local temporary tables are dropped automatically at the end of the current session.
You can read more from the below link.
https://technet.microsoft.com/en-us/library/aa258255(v=sql.80).aspx
If you have any question, feel free to let me know.
Eric Zhang
TechNet Community Support -
Scheduled job that drops temp tables.
Hi, I have a 3rd party app that creats temp tables and never drops them. I need to come up with a scrip that I can run every thirty days and clean them up. Here is the select I run to find them. I just don't know how to format the drop statement.
select owner, object_name, created from dba_objects where object_name like 'DWTEMP%' and created > '01-MAY-11' and object_type='TABLE';
Thanks
BryanIt sounds like you want something like
BEGIN
FOR tbl IN (select owner, object_name, created
from dba_objects
where object_name like 'DWTEMP%'
and created BETWEEN trunc(sysdate) - 30 AND trunc(sysdate)
and object_type='TABLE')
LOOP
EXECUTE IMMEDIATE 'DROP TABLE ' || tbl.owner || '.' || tbl.object_name || ' PURGE';
END LOOP;
END;or
BEGIN
FOR tbl IN (select owner, object_name, created
from dba_objects
where object_name like 'DWTEMP%'
and created BETWEEN add_months(trunc(sysdate), -1) AND trunc(sysdate)
and object_type='TABLE')
LOOP
EXECUTE IMMEDIATE 'DROP TABLE ' || tbl.owner || '.' || tbl.object_name || ' PURGE';
END LOOP;
END;depending on whether you want to go back 30 days or 1 month.
Justin -
Not able to drop Temp tables in staging schema
Dear All,
I am facing some issue with the temporary tables in my interface; i am using ODI 11g,
Getting following error;
Message:
ODI-1228: Task FEED_NL_STEP_UPDATE_DATA_TO_XML_WS (Integration) fails on the target XML connection XML_DS_NL_LISTOFACTIVITY.
Caused By: java.sql.SQLException: ORA-00942: table or view does not exist
Code:
Drop Table: C$_ACTIVITY
I heard that there is some known bug in ODI with respect this error.
Please help me to find workaround for the same..
Thanks and Regards
Sanwell,
When I check my staging schema where this table is supposed to be created, I see the table.
But ODI is thorwing error saying 'ODI-1228: Task FEED_NL_STEP_UPDATE_DATA_TO_XML_WS (Export) fails on the target XML connection XML_DS_NL_LISTOFACTIVITY.
Caused By: java.sql.SQLException: ORA-00942: table or view does not exist'
Even though the table exists physically, ODI is not able to detect is somehow. so need to know why this is happening and how to resolve this.
Thanks
San -
Better to have temp tables or create/drop
Greetings:
This is a question more for the DBA types out there. Generally speaking, if you need a place to store temp. data from a forms application, is it better to have a temp table sitting out there all the time and just truncate it, or create/drop the table as needed? I wondering from a performance standpoint but also, which is worse as far as fragmenting my tablespaces?
Thanks
[email protected]It's better to have it sitting there. Moreover, that table would better have a column (say sesssid) that would be populated with the return of userenv('sessionid') which corresponds to audsid from sys.v_$session.
So, you may periodically run a stored proc that deletes the rows having sessid values that does
delete from temp_table where sessid
not in (select audsid from sys.v_$session).
So, you won't be deleting the data needed by the currently running sessions.
Creating and dropping temp tables gives much fragmentation and degrades performance.
null -
CF 6.1, cfquery, MySQL, and temp tables
I have a need to use a temp table for a page, and I'm finding
that temporary tables are not temporary when creating them via CF.
The temporary table is not being dropped when the page is
done processing, and what's worse is that when running the page
from multiple browsers, the temporary table is being SHARED across
requests, defeating the whole purpose of a "private" temporary
table for each request of the table.
I have a feeling this has something to do with the way CF
maintains its connection pool, but I'd like to know the real story
from anyone who knows. And even better, I'd like to know how to
prevent this from happening :)
The fact that the table isn't dropping automatically doesn't
bother me; I can always drop it manually. However the fact that I
can request the page on one computer, then go to another computer
and request it and I'm using the same temp table. I consider that a
deal breaker.
Any ideas?> the table isn't dropping automatically doesn't bother me
I think the reason why the temp tables are not being dropped
automatically
is because CF caches Connection(s) to the database.
Perhaps it's better to drop temp tables than to have CF
re-create connections
to the database for each client request?
I think there is a setting in CF Admin where you can specify
a DSN to NOT
to maintain connections across client requests? This might do
what you
are looking for but it may not be what you want.
Good luck! -
Temp tables not dropped SQL Server 2012
I have a server that houses a database application that makes heavy use of temp tables. It appears that temp tables are not getting dropped from the tempdb. In perfmon the temp table count is hanging around 1000 and is not going down over time.
Even if the programmers are not using drop table at the end of their sps, shouldn't these temp tables be cleaned up when they go out of scope?
Jeffshouldn't these temp tables be cleaned up when they go out of scope?
Hello Jeff,
If global temp tables (##temp) are used, then they will be dropped if no session any longer reference this temp table. Local temp table will be dropped as soon as the session, which created the temp table, is closed.
See CREATE TABLE (Transact-SQL) => Remarks => Temporary Tables
Olaf Helper
[ Blog] [ Xing] [ MVP] -
PL/SQL to create a temp table that will be dropped after session ends
Is it possible in PL/SQL to create a temp table that will be dropped after the session ends? Please provide example if possible. I can create a global temp table in PL/SQL but I am not sure how (if possible) to have it 'drop' once the session ends.
DB: 10g
OS: Wiindoze 2003 Server
:-)As others have mentioned (but probably not clearly explained), Oracle treats temporary tables differently to SQL Server.
In SQL Server you create a temporary table and it gets dropped (automatically I assume, I dont do SQL Server) after the session finishes. This will obviously allow each session to "request" a temporary table to use, then use it, and not have to worry about cleaning up the database after the session has finished.
Oracle takes a different approach...
On the assumption that each session is likely to be creating a temporary table for the same purposes, with the same structure, Oracle let's you create a Global Temporary Table a.k.a. GTT (which you've already come across). You only have to create this table once and you leave it on the database. This then means that any code written to use that table doesn't have to be dynamic code and can be verified and checked at compile time, just like code written for any other table. The difference of a GTT from a regular table is that any data you put into that table can only be seen by that session and will not interfere with any data of other sessions and, when you either commit, or end the session (depending on the "on commit delete rows" or "on commit preserve rows" option used when creating the GTT), that data from your own session will automatically be removed and hence the table is cleaned up that way, whilst the actual table itself remains.
Some people from SQL Server backgrounds try and create and drop tables dynamically in their PL/SQL code, but this leads to problems...
SQL> ed
Wrote file afiedt.buf
1 begin
2 execute immediate 'create table my_temp (x number)';
3 insert into my_temp values (1);
4 execute immediate 'drop table my_temp';
5* end;
SQL> /
insert into my_temp values (1);
ERROR at line 3:
ORA-06550: line 3, column 15:
PL/SQL: ORA-00942: table or view does not exist
ORA-06550: line 3, column 3:
PL/SQL: SQL Statement ignoredi.e. the code will not compile for direct DML statements trying to use that table.
They then try and get around this issue by making their DML statements dynamic too...
SQL> ed
Wrote file afiedt.buf
1 create or replace procedure my_proc is
2 begin
3 execute immediate 'create table my_temp (x number)';
4 execute immediate 'insert into my_temp values (''A'')';
5 execute immediate 'drop table my_temp';
6* end;
SQL> /
Procedure created.... which looks great and it compiles ok... but... when they try and run it...
SQL> exec my_proc;
BEGIN my_proc; END;
ERROR at line 1:
ORA-01722: invalid number
ORA-06512: at "SCOTT.MY_PROC", line 4
ORA-06512: at line 1... oops the code has a bug in it. Our DML statement was invalid.
This is really something that would have been caught at compile time, if the statement had been a direct DML statement rather than dynamic. And thus we see the problem with people trying to write all their code as dynamic SQL... it's more likely to contain bugs that won't be detected at compile time and only come to light at run time... sometimes only under certain conditions and sometimes once it's got into a production environment. Bad Idea!!!! ;)
Far better to never create tables (or most other database objects) at run time. Just create them once as part of the database design/implementation and use them as required, allowing you to catch the most common coding errors up front before they get anywhere near a test environment or worse still, a production environment. -
Can't Drop a table in DB2 UDB on Windows 2003 server Ent EDT
Previus step:
Database DB2 ibm for a sap BW production got error in log - cause: no space on disk.
system mark database as bad.
system connection with db was restored with sap and ibm support
I'm in disaster recovery situation,
we have rebuilded index and table that got problem in db2dart report.
Now Sap system go up, we have successfully dumped 29 of 30 tables with db2dart /ddel command, now there is only a table that got problem:
sapbw2.rsbatchdata
we can't drop this table.
We try with this step:
1) db2dart bw2 /ddel
(table id)1837 (tablespaceid)10 0 9000000
we obtain a SQL file
2) db2dart bw2 /mt
(table id)1837 (tablespaceid)10 (password that you provide)
3) db2 drop bw2 sapbw2.rsbatchdata after this command we got a crash database.
2008-05-29-16.33.59.148000+120 I5094483F478 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : section stmt
DATA #1 : Hexdump, 29 bytes
0x000000003806E1F4 : 6472 6F70 2074 6162 6C65 2073 6170 6277 drop table sapbw
0x000000003806E204 : 322E 5253 4241 5443 4844 4154 41 2.RSBATCHDATA
2008-05-29-16.33.59.148000+120 I5094963F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: section stmt
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.148000+120 I5095124F174 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: informational text for dump
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.148000+120 I5095300F166 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: Unrelocation Needed
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.148000+120 I5095468F204 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: Section relocated; reltables in global cache inaccessible
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.148000+120 I5095674F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: section ptr
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.163000+120 I5095834F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: section size
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.163000+120 I5095995F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: dynamic ptr
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.163000+120 I5096155F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: dynamic size
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.163000+120 I5096316F165 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: shared dynamic ptr
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.163000+120 I5096483F166 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: shared dynamic size
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.163000+120 I5096651F169 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: dynamic section header
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.179000+120 I5096822F164 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: offset in section
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.179000+120 I5096988F153 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: opcode
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.179000+120 I5097143F155 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: agg_mode
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.179000+120 I5097300F155 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: section1
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.179000+120 I5097457F168 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: End of dumped section
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.241000+120 I5097627F438 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, access plan manager, sqlra_sqlC_dump, probe:25
MESSAGE : Context info dumped! Check
t1srv5bw\db2dumpBW2\a71646016.000 for
additional data.
2008-05-29-16.33.59.273000+120 I5098067F452 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, access plan manager, sqlra_sqlW_raw_dump, probe:25
MESSAGE : Private workspace info dumped! Check
t1srv5bw\db2dumpBW2\a71646016.000 for additional data.
2008-05-29-16.33.59.288000+120 I5098521F451 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, access plan manager, sqlra_sqlW_raw_dump, probe:25
MESSAGE : Shared workspace info dumped! Check
t1srv5bw\db2dumpBW2\a71646016.000 for additional data.
2008-05-29-16.33.59.304000+120 I5098974F450 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, access plan manager, sqlra_cache_full_dump, probe:25
MESSAGE : Package Cache info dumped! Check
t1srv5bw\db2dumpBW2\a71646016.000
for additional data.
2008-05-29-16.33.59.335000+120 I5099426F166 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: **** DRDA ASCB ****
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.335000+120 I5099594F171 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: **** DRDA CMNMGR CB ****
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.335000+120 I5099767F171 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: **** RECEIVE BUFFER ****
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.335000+120 I5099940F169 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: **** SEND BUFFERS ****
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.335000+120 I5100111F174 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: **** CONNECTION HANDLE ****
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.335000+120 I5100287F172 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: **** DRDA ATTRIBUTES ****
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.351000+120 I5100461F171 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: **** AS UCINTERFACE ****
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.351000+120 I5100634F468 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrr_dump_ffdc, probe:902
RETCODE : ZRC=0x87020002=-2029912062=SQLB_BPSE "Debug logic error detected"
DIA8501C A buffer pool logic error has occurred.
2008-05-29-16.33.59.351000+120 I5101104F331 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrr_dump_ffdc, probe:902
2008-05-29-16.33.59.820000+120 I5101437F156 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLE_DBCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.820000+120 I5101595F156 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_DBCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.835000+120 I5101753F400 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_AGENT_CB Pointer:
DATA #1 : Hexdump, 8 bytes
0x0000000005AA4AB0 : 0001 E637 0000 0000 ...7....
2008-05-29-16.33.59.835000+120 I5102155F160 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_AGENT_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.835000+120 I5102317F398 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_TRAN_CB Pointer
DATA #1 : Hexdump, 8 bytes
0x0000000005AA4AA0 : 8087 FD0F 0000 0000 ........
2008-05-29-16.33.59.835000+120 I5102717F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_TRAN_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.835000+120 I5102878F397 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_APP_CB Pointer
DATA #1 : Hexdump, 8 bytes
0x0000000005AA4AA8 : 0083 FD0F 0000 0000 ........
2008-05-29-16.33.59.835000+120 I5103277F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_APP_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.835000+120 I5103437F348 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : >> Begin CURSOR dump:
DATA #1 : String, 21 bytes
OPEN PERM CURSORS: >>
2008-05-29-16.33.59.851000+120 I5103787F345 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : << End CURSOR dump:
DATA #1 : String, 22 bytes
OPEN PERM CURSORS: <<
2008-05-29-16.33.59.851000+120 I5104134F348 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : >> Begin CURSOR dump:
DATA #1 : String, 21 bytes
OPEN TEMP CURSORS: >>
2008-05-29-16.33.59.851000+120 I5104484F345 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : << End CURSOR dump:
DATA #1 : String, 22 bytes
OPEN TEMP CURSORS: <<
2008-05-29-16.33.59.851000+120 I5104831F346 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : >> Begin CURSOR dump:
DATA #1 : String, 19 bytes
CLOSED CURSORS: >>
2008-05-29-16.33.59.851000+120 I5105179F364 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_CCB:
DATA #1 : String, 49 bytes
pool(TID)=0, obj(FID)=33, indexid(IID)=0, class=0
2008-05-29-16.33.59.851000+120 I5105545F155 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_CCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.851000+120 I5105702F364 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_CCB:
DATA #1 : String, 49 bytes
pool(TID)=0, obj(FID)=23, indexid(IID)=0, class=0
2008-05-29-16.33.59.851000+120 I5106068F155 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_CCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.866000+120 I5106225F342 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : << End CURSOR dump:
DATA #1 : String, 19 bytes
CLOSED CURSORS: <<
2008-05-29-16.33.59.866000+120 I5106569F154 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLI_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.866000+120 I5106725F167 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLE_AGENT_PRIVATECB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.866000+120 I5106894F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLE_APP_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.866000+120 I5107054F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLE_TRAN_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.866000+120 I5107215F156 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLP_LFPB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.929000+120 I5107373F155 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLP_ACB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.929000+120 I5107530F156 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLP_DBCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.945000+120 I5107688F168 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLP_TRAN_ENTRY_ARRAY
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.945000+120 I5107858F373 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : locklist
DATA #1 : String, 59 bytes
Check
t1srv5bw\db2dumpBW2\l57042.000 for additional data.
2008-05-29-16.33.59.960000+120 I5108233F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS AGENT CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.976000+120 I5108394F152 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLCA
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.976000+120 I5108548F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS UCINTFC
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.976000+120 I5108708F162 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS UCINTFC PID
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.976000+120 I5108872F412 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pCurrentPID->rdbcolidLen =
DATA #1 : Hexdump, 2 bytes
0x00000000056ABEA8 : 0800 ..
2008-05-29-16.33.59.976000+120 I5109286F425 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pCurrentPID->pkgnamcsn.rdbcolid =
DATA #1 : Hexdump, 8 bytes
0x00000000056ABECA : 4E55 4C4C 4944 2020 NULLID
2008-05-29-16.33.59.976000+120 I5109713F491 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pCurrentPID->rdbname =
DATA #1 : Hexdump, 18 bytes
0x00000000056ABEB8 : 4257 3220 2020 2020 2020 2020 2020 2020 BW2
0x00000000056ABEC8 : 2020
2008-05-29-16.33.59.976000+120 I5110206F491 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pCurrentPID->pkgname =
DATA #1 : Hexdump, 18 bytes
0x00000000056ABEDC : 5351 4C43 3245 3037 2020 2020 2020 2020 SQLC2E07
0x00000000056ABEEC : 2020
2008-05-29-16.33.59.976000+120 I5110699F416 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pCurrentPID->pkgcnstkn =
DATA #1 : Hexdump, 8 bytes
0x00000000056ABEEE : 4141 4141 4163 4555 AAAAAcEU
2008-05-29-16.33.59.991000+120 I5111117F406 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pCurrentPID->pkgsn =
DATA #1 : Hexdump, 2 bytes
0x00000000056ABEF6 : CB00 ..
2008-05-29-16.33.59.991000+120 I5111525F496 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pStatementText =
DATA #1 : Hexdump, 29 bytes
0x00000000062D0CC0 : 6472 6F70 2074 6162 6C65 2073 6170 6277 drop table sapbw
0x00000000062D0CD0 : 322E 5253 4241 5443 4844 4154 41 2.RSBATCHDATA
2008-05-29-16.33.59.991000+120 I5112023F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS APPL CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.991000+120 I5112183F165 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS NESTED APPL CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.991000+120 I5112350F166 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS SP REGISTERS CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.991000+120 I5112518F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS TRAN CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.33.59.991000+120 I5112678F165 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS NESTED TRAN CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.007000+120 I5112845F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS COORD CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.007000+120 I5113006F160 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS NESTED CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.007000+120 I5113168F164 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS INVOCATION CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.007000+120 I5113334F165 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS ACTIVE STMT CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.007000+120 I5113501F164 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: NLSWA:DatabaseApp
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.007000+120 I5113667F153 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: nlsacb
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.023000+120 I5113822F157 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: dbNLSAppCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.023000+120 I5113981F162 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: UnicodeNLSAppCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.023000+120 I5114145F464 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, data protection, sqlpgrlg, probe:10
MESSAGE : Error -2045771763 when reading LSN 000006BDB601F7A1 from log file
S0000000.LOG tellMe 0 dpsAcbFlags 0 setSkipOutputBuf 0
2008-05-29-16.34.00.023000+120 I5114611F468 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, data protection, sqlpgrlg, probe:10
MESSAGE : NOTE: The log state was marked bad by another process, this message
is not an indication of an error with the logger process
2008-05-29-16.34.00.523000+120 I5115081F457 LEVEL: Error
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, data protection, sqlpgrlg, probe:10
RETCODE : ZRC=0x8610000D=-2045771763=SQLP_BADLOG "Log File cannot be used"
DIA8414C Logging can not continue due to an error.
2008-05-29-16.34.00.538000+120 I5115540F459 LEVEL: Error
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, data protection, sqlptudo, probe:1010
RETCODE : ZRC=0x8610000D=-2045771763=SQLP_BADLOG "Log File cannot be used"
DIA8414C Logging can not continue due to an error.
2008-05-29-16.34.00.538000+120 I5116001F455 LEVEL: Warning
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, data protection, sqlptudo, probe:4350
MESSAGE : LSN being undone:
DATA #1 : Hexdump, 8 bytes
0x0000000005AA87A8 : 0000 06BD B601 F7A1 ........
2008-05-29-16.34.00.538000+120 I5116458F157 LEVEL: Error
PID:7164 TID:6016 NODE:000 Title: SQLP_TENTRY
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.554000+120 I5116617F166 LEVEL: Error
PID:7164 TID:6016 NODE:000 Title: SQLE_AGENT_PRIVATECB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.554000+120 I5116785F155 LEVEL: Error
PID:7164 TID:6016 NODE:000 Title: SQLP_DBCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.554000+120 I5116942F154 LEVEL: Error
PID:7164 TID:6016 NODE:000 Title: SQLP_ACB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.554000+120 I5117098F390 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, data protection, sqlptud1, probe:1880
MESSAGE : Due to error during UNDO, database will be brought down.
2008-05-29-16.34.00.570000+120 I5117490F459 LEVEL: Error
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, data protection, sqlpxrbk, probe:3040
RETCODE : ZRC=0x8610000D=-2045771763=SQLP_BADLOG "Log File cannot be used"
DIA8414C Logging can not continue due to an error.
2008-05-29-16.34.00.570000+120 I5117951F155 LEVEL: Error
PID:7164 TID:6016 NODE:000 Title: SQLP_DBCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.570000+120 I5118108F154 LEVEL: Error
PID:7164 TID:6016 NODE:000 Title: SQLP_ACB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.00.570000+120 I5118264F384 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : cr_error:
DATA #1 : Hexdump, 4 bytes
0x00000000056AF4C8 : 0100 0000 ....
2008-05-29-16.34.00.570000+120 I5118650F465 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrrbck_dps, probe:20
RETCODE : ZRC=0x8610000D=-2045771763=SQLP_BADLOG "Log File cannot be used"
DIA8414C Logging can not continue due to an error.
2008-05-29-16.34.00.585000+120 I5119117F692 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
DATA #1 : SQLCA, PD_DB2_TYPE_SQLCA, 136 bytes
sqlcaid : SQLCA sqlcabc: 136 sqlcode: -902 sqlerrml: 1
sqlerrmc: 2
sqlerrp : SQLRL281
sqlerrd : (1) 0x87020002 (2) 0x00000002 (3) 0x00000000
(4) 0x00000000 (5) 0x00000000 (6) 0x00000000
sqlwarn : (1) (2) (3) (4) (5) (6)
(7) (8) (9) (10) (11)
sqlstate:
2008-05-29-16.34.00.585000+120 I5119811F418 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, global services, sqlzerdm, probe:40
DATA #1 : Hexdump, 4 bytes
0x0000000005AA8B08 : 0D00 1086 ....
2008-05-29-16.34.01.070000+120 I5120231F461 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrrbck, probe:40
RETCODE : ZRC=0x8610000D=-2045771763=SQLP_BADLOG "Log File cannot be used"
DIA8414C Logging can not continue due to an error.
2008-05-29-16.34.01.070000+120 I5120694F474 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrr_rds_common_post, probe:88
RETCODE : ZRC=0x8610000D=-2045771763=SQLP_BADLOG "Log File cannot be used"
DIA8414C Logging can not continue due to an error.
2008-05-29-16.34.01.070000+120 I5121170F435 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrr_rds_common_post, probe:190
DATA #1 : Hexdump, 4 bytes
0x0000000005AA8F6C : 0200 0287 ....
2008-05-29-16.34.01.070000+120 I5121607F383 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : UCstate:
DATA #1 : Hexdump, 4 bytes
0x00000000056AFA70 : 4200 0004 B...
2008-05-29-16.34.01.070000+120 I5121992F692 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
DATA #1 : SQLCA, PD_DB2_TYPE_SQLCA, 136 bytes
sqlcaid : SQLCA sqlcabc: 136 sqlcode: -984 sqlerrml: 1
sqlerrmc: 2
sqlerrp : sqlrrbkd
sqlerrd : (1) 0x8610000D (2) 0xFFFFFC2C (3) 0x00000000
(4) 0x00000000 (5) 0x00000000 (6) 0x00000000
sqlwarn : (1) (2) (3) (4) (5) (6)
(7) (8) (9) (10) (11)
sqlstate:
2008-05-29-16.34.01.070000+120 I5122686F508 LEVEL: Error
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, DRDA Application Server, sqljsTermAgentReply, probe:10
MESSAGE : DIA5000C A DRDA AS token "AGENT TERMINATING" was detected. The
diagnostic data returned is (SRVDGN): "SQLERRP:sqlrrbkd
SQLCODE:-984".
2008-05-29-16.34.01.085000+120 I5123196F691 LEVEL: Error
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
DATA #1 : SQLCA, PD_DB2_TYPE_SQLCA, 136 bytes
sqlcaid : SQLCA sqlcabc: 136 sqlcode: -984 sqlerrml: 1
sqlerrmc: 2
sqlerrp : sqlrrbkd
sqlerrd : (1) 0x8610000D (2) 0xFFFFFC2C (3) 0x00000000
(4) 0x00000000 (5) 0x00000000 (6) 0x00000000
sqlwarn : (1) (2) (3) (4) (5) (6)
(7) (8) (9) (10) (11)
sqlstate:
2008-05-29-16.34.01.085000+120 I5123889F375 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrr_dump_ffdc, probe:20
RETCODE : ZRC=0x00000000=0=PSM_OK "Unknown"
2008-05-29-16.34.01.085000+120 I5124266F692 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
DATA #1 : SQLCA, PD_DB2_TYPE_SQLCA, 136 bytes
sqlcaid : SQLCA sqlcabc: 136 sqlcode: -1034 sqlerrml: 0
sqlerrmc:
sqlerrp : SQLRR09E
sqlerrd : (1) 0x00000000 (2) 0x00000000 (3) 0x00000000
(4) 0x00000000 (5) 0xFFFFFFE2 (6) 0x00000000
sqlwarn : (1) (2) (3) (4) (5) (6)
(7) (8) (9) (10) (11)
sqlstate:
2008-05-29-16.34.01.085000+120 I5124960F152 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLCA
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.085000+120 I5125114F385 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : CREATOR
DATA #1 : Hexdump, 8 bytes
0x0000000037E6D1AE : 4E55 4C4C 4944 2020 NULLID
2008-05-29-16.34.01.085000+120 I5125501F385 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : PACKAGE
DATA #1 : Hexdump, 8 bytes
0x0000000037E6D1CC : 5351 4C43 3245 3037 SQLC2E07
2008-05-29-16.34.01.101000+120 I5125888F154 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: CREATOR
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.101000+120 I5126044F154 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: PACKAGE
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.101000+120 I5126200F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: REQUEST TYPE
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.101000+120 I5126361F162 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: APM COMMON INFO
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.101000+120 I5126525F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: CONTEXT MCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.116000+120 I5126685F161 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: CONTEXT MEM CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.116000+120 I5126848F160 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: PACKAGE ENTRY
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.116000+120 I5127010F438 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, access plan manager, sqlra_sqlC_dump, probe:25
MESSAGE : Context info dumped! Check
t1srv5bw\db2dumpBW2\a71646016.000 for
additional data.
2008-05-29-16.34.01.116000+120 I5127450F452 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, access plan manager, sqlra_sqlW_raw_dump, probe:25
MESSAGE : Private workspace info dumped! Check
t1srv5bw\db2dumpBW2\a71646016.000 for additional data.
2008-05-29-16.34.01.116000+120 I5127904F451 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, access plan manager, sqlra_sqlW_raw_dump, probe:25
MESSAGE : Shared workspace info dumped! Check
t1srv5bw\db2dumpBW2\a71646016.000 for additional data.
2008-05-29-16.34.01.132000+120 I5128357F450 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, access plan manager, sqlra_cache_full_dump, probe:25
MESSAGE : Package Cache info dumped! Check
t1srv5bw\db2dumpBW2\a71646016.000
for additional data.
2008-05-29-16.34.01.132000+120 I5128809F376 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrr_dump_ffdc, probe:902
RETCODE : ZRC=0x00000000=0=PSM_OK "Unknown"
2008-05-29-16.34.01.132000+120 I5129187F331 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
FUNCTION: DB2 UDB, relation data serv, sqlrr_dump_ffdc, probe:902
2008-05-29-16.34.01.601000+120 I5129520F156 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLE_DBCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.601000+120 I5129678F156 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_DBCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.601000+120 I5129836F400 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_AGENT_CB Pointer:
DATA #1 : Hexdump, 8 bytes
0x0000000005AA8970 : 0001 E637 0000 0000 ...7....
2008-05-29-16.34.01.601000+120 I5130238F160 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_AGENT_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.616000+120 I5130400F398 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_TRAN_CB Pointer
DATA #1 : Hexdump, 8 bytes
0x0000000005AA8960 : 8087 FD0F 0000 0000 ........
2008-05-29-16.34.01.616000+120 I5130800F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_TRAN_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.616000+120 I5130961F397 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_APP_CB Pointer
DATA #1 : Hexdump, 8 bytes
0x0000000005AA8968 : 0083 FD0F 0000 0000 ........
2008-05-29-16.34.01.616000+120 I5131360F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_APP_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.616000+120 I5131520F348 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : >> Begin CURSOR dump:
DATA #1 : String, 21 bytes
OPEN PERM CURSORS: >>
2008-05-29-16.34.01.616000+120 I5131870F345 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : << End CURSOR dump:
DATA #1 : String, 22 bytes
OPEN PERM CURSORS: <<
2008-05-29-16.34.01.632000+120 I5132217F348 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : >> Begin CURSOR dump:
DATA #1 : String, 21 bytes
OPEN TEMP CURSORS: >>
2008-05-29-16.34.01.632000+120 I5132567F345 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : << End CURSOR dump:
DATA #1 : String, 22 bytes
OPEN TEMP CURSORS: <<
2008-05-29-16.34.01.632000+120 I5132914F346 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : >> Begin CURSOR dump:
DATA #1 : String, 19 bytes
CLOSED CURSORS: >>
2008-05-29-16.34.01.632000+120 I5133262F364 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_CCB:
DATA #1 : String, 49 bytes
pool(TID)=0, obj(FID)=33, indexid(IID)=0, class=0
2008-05-29-16.34.01.632000+120 I5133628F155 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_CCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.632000+120 I5133785F364 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : SQLD_CCB:
DATA #1 : String, 49 bytes
pool(TID)=0, obj(FID)=23, indexid(IID)=0, class=0
2008-05-29-16.34.01.632000+120 I5134151F155 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLD_CCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.648000+120 I5134308F342 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : << End CURSOR dump:
DATA #1 : String, 19 bytes
CLOSED CURSORS: <<
2008-05-29-16.34.01.648000+120 I5134652F154 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLI_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.648000+120 I5134808F167 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLE_AGENT_PRIVATECB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.648000+120 I5134977F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLE_APP_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.648000+120 I5135137F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLE_TRAN_CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.648000+120 I5135298F156 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLP_LFPB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.710000+120 I5135456F155 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLP_ACB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.710000+120 I5135613F156 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLP_DBCB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.710000+120 I5135771F168 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLP_TRAN_ENTRY_ARRAY
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.726000+120 I5135941F373 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : locklist
DATA #1 : String, 59 bytes
Check
t1srv5bw\db2dumpBW2\l79922.000 for additional data.
2008-05-29-16.34.01.741000+120 I5136316F159 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS AGENT CB
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.741000+120 I5136477F152 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: SQLCA
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.757000+120 I5136631F158 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS UCINTFC
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.757000+120 I5136791F162 LEVEL: Severe
PID:7164 TID:6016 NODE:000 Title: RDS UCINTFC PID
Dump File:
t1srv5bw\db2dumpBW2\71646016.000
2008-05-29-16.34.01.757000+120 I5136955F412 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pCurrentPID->rdbcolidLen =
DATA #1 : Hexdump, 2 bytes
0x00000000056ABEA8 : 0800 ..
2008-05-29-16.34.01.757000+120 I5137369F425 LEVEL: Severe
PID : 7164 TID : 6016 PROC : db2syscs.exe
INSTANCE: DB2BW2 NODE : 000 DB : BW2
APPHDL : 0-11 APPID: *LOCAL.DB2BW2.080529143349
MESSAGE : RDS UCINTFC: pCurrentPID->pkgnamcsn.rdbcolid =
DATA #1 : Hexdump, 8 bytes
0x00000000056ABECA : 4E55 4C4C 4944 2020 NULLIDI can't use db2drop because this command crash my db with this table.
So I must take another way.
============================================================
About DB2 Administration Tools Environment
============================================================
DB2 administration tools level:
Product identifier SQL08025
Level identifier 03060106
Level DB2 v8.1.12.99
Build level s060429
PTF WR21370
============================================================
Java development kit (JDK):
Level IBM Corporation 1.4.2
============================================================ -
Table or Object type - like #temp table in SQL Server
Hi
I need to create a temp table to hold certain data and then validate. What is the best way to do this oracle. Something similar to #temp tables in SQL Server.
ThanksIN Oracle, you create the temporary table once, before you start your program. Then anyone can use that definition, but the system keeps the data isolated to eachr/session.
The difference in using Oracle: all DDL, including creating temp tables, performs commits and aquires locks that you want to avoid. It creates unnecessary serialization, causes transactional consistency issues and puts Oracle's Read Consistent model at risk (of ORA-01555 errors).
So, you (or the DBA) would "CREATE GLOBAL TEMPORARY TABLE ..." with the appropriate definition you want, and indicate whether you want the data deleted on commit, or on logoff.
Then you write your procedure, similar to the way you would do it in SQL Server, but you would not bracket it with creating/dropping the temp table - no need. -
Global Temp Table or Permanent Temp Tables
I have been doing research for a few weeks and trying to comfirm theories with bench tests concerning which is more performant... GTTs or permanent temp tables. I was curious as to what others felt on this topic.
I used FOR loops to test out the performance on inserting and at times with high number of rows the permanent temp table seemed to be much faster than the GTTs; contrary to many white papers and case studies that have read that GTTs are much faster.
All I did was FOR loops which iterated INSERT/VALUES up to 10 million records. And for 10 mil records, the permanent temp table was over 500k milliseconds faster...
Anyone have an useful tips or info that can help me determine which will be best in certain cases? The tables will be used for staging for ETL Batch processing into a Data Warehouse. Rows within my fact and detail tables can reach to the millions before being moved to archives. Thanks so much in advance.
-Tim> Do you have any specific experiences you would like to share?
I use both - GTTs and plain normal tables. The problem dictates the tools. :-)
I do have an exception though that does not use GTTs and still support "restartability".
I need to to continuously roll up (aggregate) data. Raw data collected for an hour gets aggregated into an hourly partition. Hourly partitions gets rolled up into a daily partition. Several billion rows are processed like this monthly.
The eventual method I've implemented is a cross between materialised views and GTTs. Instead of dropping or truncating the source partition and running an insert to repopulate it with the latest aggregated data, I wrote an API that allows you to give it the name of the destination table, the name of the partition to "refresh", and a SQL (that does the aggregation - kind of like the select part of a MV).
It creates a brand new staging table using a CTAS, inspects the partitioned table, slaps the same indexes on the staging table, and then performs a partition exchange to replace the stale contents of the partition with that of the freshly build staging table.
No expensive delete. No truncate that results in an empty and query-useless partition for several minutes while the data is refreshed.
And any number of these partition refreshes can run in parallel.
Why not use a GTT? Because they cannot be used in a partition exchange. And the cost of writing data into a GTT has to be weighed against the cost of using that data by writing it (or some of it) into permanent tables. Ideally one wants to plough through a data set once.
Oracle has a fairly rich feature set - and these can be employed in all kinds of ways to get the job done. -
Want to use the same #TEMP table for multiple datasets in SSRS 2005
I am using Visual Studio 2005 to create SSRS 2005 reports. The report will consist of two different matrix from two different dataset that will gather data from the same data source. The first dataset is a procedure that inserts data from a query into
a #temp table and outputs it in the first matrix. I want the second dataset to be a different procedure that references the same #temp table. When the report is pulled then can the #temp table be dropped.Try in the Dataset properties. In the Query tab, under and to the right of "Data source:" click the box with the elipses (...). In the General tab, toward the bottom, there is a check box beside "Use single transaction".
Rakesh M J | MCTS,MCITP ( SQL SERVER 2008 )
Dont forget to mark it as Answered if found useful |
myspeakonbi -
Unable to descripe the table and unable to drop the table
Hi,
I have a temp table that we use like staging table to import the data in to the main table through some scheduled procedures.And that will dropped every day and will be created through the script.
Some how while I am trying to drop the table manually got hanged, There after I could not find that table in dba_objects, dba_tables or any where.
But Now I am unable to create that table manually(Keep on running the create command with out giving any error), Even I am not getting any error (keep on running )if I give drop/desc of table.
Can you please any one help on this ? Is it some where got stored the table in DB or do we any option to repair the table ?
SQL> select OWNER,OBJECT_NAME,OBJECT_TYPE,STATUS from dba_objects where OBJECT_NAME like 'TEMP%';
no rows selected
SQL> desc temp
Thank in advance.Hi,
if this table drops then it moved DBA_RECYCLEBIN table. and also original name of its changed automatically by oracle.
For example :
SQL> create table tst (col varchar2(10), row_chng_dt date);
Table created.
SQL> insert into tst values ('Version1', sysdate);
1 row created.
SQL> select * from tst ;
COL ROW_CHNG
Version1 16:10:03
If the RECYCLEBIN initialization parameter is set to ON (the default in 10g), then dropping this table will place it in the recyclebin:
SQL> drop table tst;
Table dropped.
SQL> select object_name, original_name, type, can_undrop as "UND", can_purge as "PUR", droptime
2 from recyclebin
SQL> /
OBJECT_NAME ORIGINAL_NAME TYPE UND PUR DROPTIME
BIN$HGnc55/7rRPgQPeM/qQoRw==$0 TST TABLE YES YES 2013-10-08:16:10:12
All that happened to the table when we dropped it was that it got renamed. The table data is still there and can be queried just like a normal table:
SQL> alter session set nls_date_format='HH24:MI:SS' ;
Session altered.
SQL> select * from "BIN$HGnc55/7rRPgQPeM/qQoRw==$0" ;
COL ROW_CHNG
Version1 16:10:03
Since the table data is still there, it's very easy to "undrop" the table. This operation is known as a "flashback drop". The command is FLASHBACK TABLE... TO BEFORE DROP, and it simply renames the BIN$... table to its original name:
SQL> flashback table tst to before drop;
Flashback complete.
SQL> select * from tst ;
COL ROW_CHNG
Version1 16:10:03
SQL> select * from recyclebin ;
no rows selected
It's important to know that after you've dropped a table, it has only been renamed; the table segments are still sitting there in your tablespace, unchanged, taking up space. This space still counts against your user tablespace quotas, as well as filling up the tablespace. It will not be reclaimed until you get the table out of the recyclebin. You can remove an object from the recyclebin by restoring it, or by purging it from the recyclebin.
SQL> select object_name, original_name, type, can_undrop as "UND", can_purge as "PUR", droptime
2 from recyclebin
SQL> /
OBJECT_NAME ORIGINAL_NAME TYPE UND PUR DROPTIME
BIN$HGnc55/7rRPgQPeM/qQoRw==$0 TST TABLE YES YES 2006-09-01:16:10:12
SQL> purge table "BIN$HGnc55/7rRPgQPeM/qQoRw==$0" ;
Table purged.
SQL> select * from recyclebin ;
no rows selected
Thank you
And check this link:
http://www.orafaq.com/node/968
http://docs.oracle.com/cd/B28359_01/server.111/b28310/tables011.htm
Thank you -
How do I CREATE IF NOT EXISTS Temp table in PLSQL?
hello, how do I CREATE IF NOT EXISTS Temp table in PLSQL? The following table is to be created in FIRST call inside a recursive function (which you'll see in QUESTION 2).
QUESTION 1:
CREATE GLOBAL TEMPORARY TABLE TmpHierarchyMap
Id numeric(19,0) NOT NULL,
ParentId numeric(19,0) NOT NULL,
ChildId numeric(19,0) NOT NULL,
... more ...
) on commit delete rows');
QUESTION 2: How to return a temp table from a function?
For example, this is how I'm doing it at the moment, using Nested Table.
EXECUTE IMMEDIATE 'CREATE OR REPLACE TYPE TmpHierarchyMapObjType AS OBJECT
Id numeric(19,0) ,
ParentId numeric(19,0),
ChildId numeric(19,0),
... more ...
EXECUTE IMMEDIATE 'CREATE OR REPLACE TYPE TmpHierarchyMapTableType AS TABLE OF TmpHierarchyMapObjType;';
CREATE OR REPLACE FUNCTION fnGetParentsTable
ObjectId number,
ObjectClassifier varchar2
RETURN TmpHierarchyMapTableType
IS
TmpHierarchyMap TmpHierarchyMapTableType := TmpHierarchyMapTableType();
ThisTempId varchar2(32);
CURSOR spGetParents_cursor IS
SELECT
Id,
ParentId,
ChildId,
FROM TMP_HIERARCHYMAP
WHERE TempId = ThisTempId;
BEGIN
SELECT sys_guid() INTO ThisTempId FROM dual;
spRecursiveGetParents(ObjectId, ObjectClassifier, ThisTempId);
FOR oMap in spGetParents_cursor LOOP
TmpHierarchyMap.Extend();
TmpHierarchyMap(TmpHierarchyMap.Count) := TmpHierarchyMapObjType( oMap.Id
, oMap.ParentId
, oMap.ChildId
END LOOP;
DELETE FROM TMP_HIERARCHYMAP WHERE TempId = ThisTempId;
RETURN TmpHierarchyMap;
END fnGetParentsTable;
QUESTION 3: what does the word GLOBAL means? I read that temp table is visible only to a particular database connection/session and will be dropped automatically on termination of the session. i can only find this information in some forum discussion but failed to locate this in Oracle doc, can someone point me in right direction please?
Many thanks!
REF:
http://stackoverflow.com/questions/221822/sybase-developer-asks-how-to-create-a-temporary-table-in-oracle
http://www.oracle-base.com/articles/8i/TemporaryTables.phpdevvvy wrote:
so if I CREATE GLOBAL TEMPORARY TABLE twice on second pass of my recursive function what then...?You don't create it inside your function.
You create the GTT once on your database outside of the function and then just leave it there and use it.
Tables should not be dynamically created and dropped.
Only other database engines such as SQL Server use the concept of creating temporary tables during the execution of code. Oracle uses a "create once, use whenever" methodology. -
Does Oracle support #temp tables like SQL Server 7? And if it does, then how? Thank you very much in advance.
For Oracle8i and above, you could use something like the following:
drop type Humans
create or replace type Human is Object (
Name VARCHAR2(50),
Age NUMBER(3)) ;
show errors
create or replace TYPE Humans is TABLE of Human ;
show errors
set serveroutput on
declare
tbl Humans ;
cnt number ;
begin
tbl := Humans(NULL) ;
tbl(1) := Human('First', 39) ;
tbl.Extend ;
tbl(2) := Human('Second', 55) ;
select count(*) into cnt from TABLE(CAST(tbl AS Humans)) ;
dbms_output.put_line('Total rows in Humans table:'||cnt) ;
end ;
Maybe you are looking for
-
Quick Question about Transposing/Crosstab SQL or PL/SQL query
Hi All, Looking for how to transpose rows into column in SQL and/or PLSQL I've got thousands of rows in the format phone_no Code 4161231234 A 4161231234 B 4161231234 C 6471231234 A 6471231234 B 6471231234 C need to transpose this to phone_no Code_1 C
-
Which table stores the Sales Order--Header--Texts--EDI Text?
Hi Experts, I hv a requirenment regarding the Sales Order -> HEADER -> TEXTs -> EDI Text-Int, so, I need to hv some Orders(#). which does hv this text on them, for as test data. So, I am looking which table stores, this text for my_sales_oders_123456
-
Hi, I need to Convert a text file in a specific format to table. Please find the attachment for the text file. the table contains columns Section, Address, Data, Attribute. Anybody please share me a sample VI to implement the above. -mfp. Attachments
-
Stinkin' "PREVIEW" app opening all my EPS & PDF files–HELP
All of my EPS and PDF documents are now defaulting to open in PREVIEW. Anyway to assign them to open in Acrobat and Illustrator as they used to? I am aware of the manual way to do it it's just inconvenient. Any input is appreciated. Thanks
-
Import Libraries (jar) into DC Project
Hi all, I want to create a J2EE application with an DC Web-Modul. I have to import any jar libraries for other functions (struts.jar etc.). I have imported the library in the project settings: properties ->java buildpath -> add external jars. But it