OBIA on Teradata - Part 3 Stats
- by Mohan Ramanuja
Statements to run table stats on W_Party_Per_DS and W_Party_Per_DCOLLECT STATISTICS ON W_PARTY_PER_DS COLUMN ("DEPARTMENT_NAME");COLLECT STATISTICS ON W_PARTY_PER_DS COLUMN ("CONTACT_ID");COLLECT STATISTICS ON W_PARTY_PER_DS COLUMN ("CITY");COLLECT STATISTICS ON W_PARTY_PER_D COLUMN ("ACCNT_FLG");COLLECT STATISTICS ON W_PARTY_PER_D COLUMN ("SUPPLIER_FLG");help statistics w_party_per_d;
Date Time Unique Values Column Names10/06/02 15:37:47 5,002,185 ROW_WID10/06/21 14:02:55 0 VIS_PR_POS_ID10/06/02 15:37:48 2 CREATED_BY_WID10/06/02 15:37:49 2 CHANGED_BY_WID10/06/02 15:37:50 2 SRC_EFF_FROM_DT10/06/02 15:37:51 1 SRC_EFF_TO_DT10/06/02 15:37:52 2 EFFECTIVE_FROM_DT10/06/02 15:37:53 2 EFFECTIVE_TO_DT10/06/02 15:37:57 1 DELETE_FLG10/06/21 14:02:54 0 CURRENT_FLG10/06/02 15:37:59 2 DATASOURCE_NUM_ID10/06/02 15:38:02 1 ETL_PROC_WID10/06/10 18:27:21 1,000 INTEGRATION_ID
select top 10 * from DBC.TableSize;
VprocDataBaseName AccountName TableName CurrentPerm PeakPerm
0 T21_ETL_TEMP_ENT IM IT/IM IT Enterprise region RZ_PENDD_FCLTY_CLM_STG 1024 0
0 SSB_RDS IM IT/IM IT ENTERPRISE REGION RDS_RESP_997_TLR 1024 0
0 T17_EDL IM IT/IM IT Enterprise region SPCMN_ACTN 1024 0
0 T20_ETL_CAPTR_DATA_ENT IM IT/IM IT Enterprise region HZ_CS90_VSGPNTE_S9MGNT14 2048 0
0 T5_ETL_DATA_PBM IM IT/IM IT Enterprise region PRCG_OVRD_BY_RX_NM 1536 0
0 PIP_DB $H&D&H PIPTRGENTSRC 1024 0
0 STest5_ADW0 sysadmin PROV_RGSTRTN 59904 0
0 AEDWSTG1 NEIM/NEIM MEMBERSHIP_LKUP_ETL 1024 0
0 AEDWTST5 dbc cptn_agrmt_xwlk 1024 0
0 VAL_LAG_TEMP $H1$&D&HDBA clm_lag_stg 347136 0
select vproc, CurrentPerm from DBC.TableSize where databasename = 'PRJ_CRM_STGC' and tablename='w_party_per_d' ORDER BY 2 DESC;Vproc DataBaseName AccountName TableName CurrentPerm PeakPerm0 PRJ_CRM_STGC DBA/DBA W_PARTY_PER_D 8704.00 841728.003 PRJ_CRM_STGC DBA/DBA W_PARTY_PER_D 8704.00 782848.00