decode函数吗 jsp_decode函数在使用max与min的区别

源数据如图:使用max语句:selects.os_username,max(decode(s.unix_host,'192.168.0.20',to_char(s.create_date,'yyyy-mm-dd'),'no'))贰零,min(decode(s.unix_host,'192.168.0.23',to...

源数据如图:

使用max语句:

select s.os_username, max(decode(s.unix_host,'192.168.0.20',to_char(s.create_date,'yyyy-mm-dd'),'no')) 贰零, min(decode(s.unix_host,'192.168.0.23',to_char(s.create_date,'yyyy-mm-dd'),'no')) 贰叁, min(decode(s.unix_host,'192.168.0.26',to_char(s.create_date,'yyyy-mm-dd'),'no')) 贰陆from service sgroup by s.os_username;

使用max的结果:

使用min语句:

select s.os_username, min(decode(s.unix_host,'192.168.0.20',to_char(s.create_date,'yyyy-mm-dd'),'no')) 贰零, min(decode(s.unix_host,'192.168.0.23',to_char(s.create_date,'yyyy-mm-dd'),'no')) 贰叁, min(decode(s.unix_host,'192.168.0.26',to_char(s.create_date,'yyyy-mm-dd'),'no')) 贰陆from service sgroup by s.os_username;

使用min的结果:

请问 为什么 在使用 max 时 贰零列 出来的数据是日期的个数 和使用 min 不一样

应该不管用max还是min 出来的‘no’的个数该相同的啊!?

求解……

展开

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值