zfxcms ^回到顶部

您的当前位置:首页 > 最新IT资讯 > MySQL > select小技巧-增加自定义行或列

select小技巧-增加自定义行或列

所属分类: MySQL   2019-11-05 15:30:49  编辑:admin  浏览次数 709 次

select 查询多一行自定义列表

select 0 as id,'请选择' as title union all

select gid as id,gname as title from 表名 where status=0 

select 查询多一列自定义字段

select gid as id,gname as title ,0 as pid from 表名 where status=0 


随笔文章检索

随笔文章目录