读书人

大侠这个查询出的字段中‘0’ 代表着

发布时间: 2012-04-16 16:20:04 作者: rapoo

请教各位大侠,这个查询出的字段中‘0’ 代表着什么意思啊?

SQL code
select share_id ,user_id, source_id, target_id,source_type,target_type,hide,c_time, 0 comment_type,0 firstname,0 lastname,0 state,0 handle,0 face, 0 sc_id,0 sc_content,0 sc_time,0 lc_id,0 lc_content,0 lc_time,0 tc_id,0 tc_content,0 tc_time from...


请教各位大侠,这个查询出的字段中‘0’ 代表着什么意思啊,有些需要‘0’,又有些不需要,这个是为什么呢?

[解决办法]
0 comment_type=>0 as comment_type
生成值为0的若干列
[解决办法]
生成一些固定的列。

和 select 1 from table1; 一样。
[解决办法]
就是代表这一列全是0
[解决办法]
生成固定的列0

读书人网 >Mysql

热点推荐