2026-03-12 21:01:38
This commit is contained in:
19
tiddlywiki/obj_stats_history.sql.txt
Executable file
19
tiddlywiki/obj_stats_history.sql.txt
Executable file
@@ -0,0 +1,19 @@
|
||||
SET LINE 180
|
||||
SET PAGES 50
|
||||
|
||||
COL OWNER FOR A20
|
||||
COL OBJECT_NAME FOR A20
|
||||
|
||||
define OWNER=AINSREQ1
|
||||
define OBJECT_NAME=INS_MKT_SUMMARY_J
|
||||
|
||||
SELECT
|
||||
OBJ.OWNER,OBJ.OBJECT_NAME,ANALYZETIME,HS.ROWCNT,HS.BLKCNT,HS.SAMPLESIZE
|
||||
FROM
|
||||
DBA_OBJECTS OBJ, WRI$_OPTSTAT_TAB_HISTORY HS
|
||||
WHERE
|
||||
OBJ.OWNER='&OWNER' AND OBJ.OBJECT_NAME='&OBJECT_NAME' AND OBJ.OBJECT_ID=HS.OBJ#
|
||||
ORDER BY
|
||||
ANALYZETIME ASC;
|
||||
|
||||
select num_rows from dba_tables where owner='&OWNER' AND table_name='&OBJECT_NAME';
|
||||
Reference in New Issue
Block a user