
This leads me to complain about the stupid syntax for if then in the derived column expression editor as shown below:
[Expression the create a true false result] ? [Then data value] : [Else data value]
I have no idea where this came from and it took me forever to find this. This is the link to MSDN.
This can all be accomplish with a single transact SQL statement using a temp table variable and this makes it look really complicated.