yes exactly. you got it right. I am pretty sure, mapping is not done purely on name.
may be mapping holds good between two Query transformsbut not between a SQL transform and query transform.
let me explain you in detail.
suppose there are 5 columns initially(abc,def, ghi, jkl,mno) . which worked fine
now source schema added one more column 6th at the end (alphabetically last in the table, i.e. PQR) then the code might work. but if the newly added column comes in between the original 5 columns (say BCD) then I can guarantee you it will swap the result set.
we have faced lot of issues on this. please revisit this once.