【发布时间】:2016-04-06 15:48:05
【问题描述】:
我正在为一个复杂的 If Then Else 语句编写一个 select case 语句,其中逻辑是
If (wp.LINE_OF_BUSINESS = 'A' or wp.LINE_OF_BUSINESS = 'U') and (wr.Relate_Code = 'in') then bf.age
else if (wp.LINE_OF_BUSINESS = 'A' or wp.LINE_OF_BUSINESS = 'U') and (wr.Relate_Code = 'je' or wr.Relate_Code = 'ji') then then bf.age2
else ba.age
如果发生 then 语句,我该如何编写这个逻辑?
谢谢
【问题讨论】:
-
您认为哪里有困难?
标签: sql sql-server