Server 2008中有一个SQL查询,如下所示:declare @Waited8_12 varchar(max)declare @Waited12_18 varchar(max) = 'true'
choice = case when @Waited6_8 = 'true' then '6-true' then '8-12'
我正在使用Oracle示例:2) 1,2,3,5,11第一个例子是我遇到的问题。我正在编写一个select查询,如: SELECT * from Table where Value IN (1,2,3,6-8,9-11)SELECT * from Table where Value IN (1,2,3,6,7,8,9,10,1
我试图将这个CASE语句设置为一个变量,但我在列中得到了相同的日期。这条特殊的CASE语句正在根据夏令时进行调整。我在其他查询中都使用它,但我想缩短这些查询,只在顶部将它作为一个变量。CASE WHEN OR a.REQDATE BETWEEN '2015-11-01' AND '2016-03-13'
OR a.REQDATE B