How to Substitute a String if record is NULL in T-SQL

后端 未结 3 1692
温柔的废话
温柔的废话 2020-12-11 16:13

I\'m writing a T-SQL report that shows the number of accounts that are in different statuses for different customers. The report results in something like:

C         


        
3条回答
  •  天命终不由人
    2020-12-11 16:59

    SELECT
       sr.sales_region_name   AS SalesRegion
       , ISNULL(micv.value,'Pending')
       , COUNT(sr.sales_region_name)
    FROM prospect p
    --(...)
    

    Go check ISNULL for further info.

提交回复
热议问题