gate_s

  博客园 :: 首页 :: 新随笔 :: 联系 :: 订阅 :: 管理 ::

04 2015 档案

摘要:在数据库中有个表aa现在要根据名称分组,选择最大日期和最小日期的数据,并显示在一行上,首先要根据名称分组,取得最大日期 然后 union all 根据名称分组,选取最小日期,效果如图select top 100 percent aa.names,aa.s,aa.createdate from ( ... 阅读全文
posted @ 2015-04-28 19:22 gate_s 阅读(1039) 评论(0) 推荐(0)