1 .The below collect stats statment on volatile table in Teradata Bteq script returns no rows changed . Can some one help me to understand whether the stats are collected or not ?.
collect stats on ORDER_VT column (ORDER_ID);
** Update completed. No rows changed. *** Total elapsed time was 16 seconds.
2.Trying to collect the stats on below volatile created in two different ways .
- Collect stats on all columns at a time
- Collecting stats on each column individually Whats make the the difference here .
Create multiset volatile table TEST1 as ( select COLMN1, COLMN2, COLMN3, from TABLE1 T1 inner join TABLE2 T2 on T1.KEY1=T2.KEY1 AND T1.KEY2=T2.KEY2 )WITH DATA PRIMARY INDEX(COLMN1,COLMN2,COLMN3) ON COMMIT PRESERVE ROWS;
Collect stats on TEST1 column(COLMN1,COLMN2,COLMN3);
Collect stats on TEST1 column(COLMN1 );
Collect stats on TEST1 column(COLMN2 );
Collect stats on TEST1 column(COLMN3 );