Forum Discussion
ADDCOLUMNS - please explain!
HI igaca
Rather than try and put the logic into your ADDCOLUMNS statement at the point you create the calculated table, why not just add a calculated column to the table once you have created it with the same logic?
- Phil_Seamark8 years agoMicrosoft Employee
Oh and further to your question as to why.
I believe the formula you are using relies on a phyiscial table, and you are adding the code part way through the creation of table so it's not yet a phyisical table.
- igaca8 years agoHelper III
I already addressed the issue via a calculated column, am just trying to understand why no context transition is taking place (notice the value returned for each row is that of the entire table) to the ADDCOLUMNS (which is an iterator).
My guess is that this has something to do with the fact InputTable variable is a virtual table and does not physically map to the query-derived tables in the model but would love for someone who knows to explain what is actually going on.
Thanks for your input Phil.