2016年7月10日

orcle 按年度 月度 汇总

摘要: select mcorhr,dtype, sum(h01) as sums, datepart(year,(select left(mdate,4)+'-'+substring(mdate,5,2)+'-'+right(mdate,2))) as y, datepart(month,(select 阅读全文

posted @ 2016-07-10 20:39 静以修身! 阅读(209) 评论(0) 推荐(0) 编辑

orcle行转列

摘要: decode行转列 select name "姓名", sum(decode(subject, '语文', nvl(score, 0), 0)) "语文", sum(decode(subject, '数学', nvl(score, 0), 0)) "数学", sum(decode(subject, 阅读全文

posted @ 2016-07-10 20:37 静以修身! 阅读(295) 评论(0) 推荐(0) 编辑

导航