T-SQL: Cascading computed columns using CROSS APPLY operator

added by mehroz
1/6/2010 11:54:47 AM

275 Views

The powerful APPLY operator in Transact SQL is typically used to invoke a table-valued function for each row. But a very interesting usage of the cross apply operator is to produce a much readable code when we have several computed columns, in which the result of each one depends upon a previous one. This post describes such usage.


0 comments