我想做这样的事情(伪代码):
select case myFunction(someField) when in ('val1', 'val2', 'val3') then 'Option1'
when someOtherField = 'Val4' then 'Option2' else null end as someColumn
答案 0 :(得分:1)
var variable1 = values.TakeOrDefault(0); //getting first element or default
var variable2 = values.TakeOrDefault(1); //getting second element or default