表:table
字段:col (bit)用select查询bit型如果是1显示“是”0显示“否”

解决方案 »

  1.   

    表:table
    字段:col (bit)用select查询bit型如果是1显示“是”0显示“否”
    ------------------------------------------------------------------
    select case col when 1 then '是' else '否' end as 结果 from table
      

  2.   

    SELECT SUBSTRING('否是', col,1)
      

  3.   

    错了
    SELECT SUBSTRING('否是', col+1,1)
      

  4.   

    select case col when 1 then '是' when 0 then '否' else '' end as 结果 from table
      

  5.   

    select 
          case col 
              when 1 then '是' 
              when 0 then '否' 
              else '' end as 结果 
    from [table]--或select 
          case 
              when col=1 then '是' 
              when col=0 then '否' 
              else '' end as 结果 
    from [table]
      

  6.   

    wangtiecheng(/+〆=ろ) 的正解