数据库在中显示1或2,在程序中代表不同状态

Posted 都一样

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了数据库在中显示1或2,在程序中代表不同状态相关的知识,希望对你有一定的参考价值。

select case when H=1 then ‘在售‘
when H=2 then ‘售完‘ end
as H from HH



select * from HH
--case when then end


select HID,case H when 1 then  ‘在售‘
when 2 then ‘售完‘ end as HHu from HH

以上是关于数据库在中显示1或2,在程序中代表不同状态的主要内容,如果未能解决你的问题,请参考以下文章