记录一下,方便日后查看
SELECT USER_CODE AS '用户编码',
IF(USER_STATE = 1, '正常', '冻结') AS '用户状态',
(
CASE USER_TYPE
WHEN 1 THEN
'用户'
WHEN 2 THEN
'商家'
WHEN 3 THEN
'自营'
ELSE
'未知'
END
) AS '用户类型'
FROM
USER_INFO LIMIT 10;
记录一下,方便日后查看
SELECT USER_CODE AS '用户编码',
IF(USER_STATE = 1, '正常', '冻结') AS '用户状态',
(
CASE USER_TYPE
WHEN 1 THEN
'用户'
WHEN 2 THEN
'商家'
WHEN 3 THEN
'自营'
ELSE
'未知'
END
) AS '用户类型'
FROM
USER_INFO LIMIT 10;