Goal: the last (which is not necessarily the highest) value in a group of columns for a row as part of a stored proc.
Columns:
UniqueID, data01, data02, data03, data04, data05
The columns will be populated in order (there will never be a row without a value in 02 that has a value in 03).
If the data looks like:
ID-abc, 12, 23, 34, 43
ID-def, 11, 22, 33
I need to have returned to me the values 43 and 33 respectively.
Thanks.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
TheWkndr
Braccae tuae aperiuntur...
Columns:
UniqueID, data01, data02, data03, data04, data05
The columns will be populated in order (there will never be a row without a value in 02 that has a value in 03).
If the data looks like:
ID-abc, 12, 23, 34, 43
ID-def, 11, 22, 33
I need to have returned to me the values 43 and 33 respectively.
Thanks.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
TheWkndr
Braccae tuae aperiuntur...