在SQL

时间:2016-05-03 09:50:22

标签: sql sybase

我正在尝试在存在特定条件时累积值,例如

If statusCode = 0 then add 1 to a value.

我试图显示statusCode定义的成功记录的数量。

必须有更好的方法来做到这一点。

由于

1 个答案:

答案 0 :(得分:0)

Select count(1) from yourTable where statusCode=0 
相关问题