All Forums Database
Adeel Chaudhry 773 posts Joined 04/08
30 Aug 2015
Views - Internal execution steps

I have a quick question regarding processing of views.
Consider a view on top of a single physical table, which has a complex (pivoting and calculations) logic. Physical table is based on EAVT structure with total of 4 columns and view is transposing them and is generating about 100. And in future this number can change (most probably will increase to 1000+).
Question is, if we do a "SELECT * FROM ComplexView" or "SELECT Col1, Col2 FROM ComplexView" .... will there be any difference in computing the result?
I have had a look at the EXPLAIN plans and both are pretty same.
My understanding is regardless of the column selection in the query, Teradata will compute all columns in spool and then return only the ones that are requested.
Can you guys share your thoughts on this?

-- If you are stuck at something .... consider it an opportunity to think anew.
You must sign in to leave a comment.