我有一个mdb的数据库,其中一个ress 表格式如下,
字段 time   date
    1200  45.55
    1200  35.44
    1200  12.25
    1200  45.55
    1200  10.25
    1200  47.01
    1300  10.44
    1300  12.44
    1300  14.44
    1300  15.34
    1400  08.55
    1400  01.55
    1400  06.55
    1400  25.55
    ......上万条记录 
我要如何才能将字段time,的最后一值的date数据存到另一个表里。
如,1200  47。01
    1300  15。34
    1400  25。55
    ......
该如何实现了,谢谢各位/。////

解决方案 »

  1.   

    select time,max(date) from ress group by time
      

  2.   

    哇,这道题有100分,顶下。
    select time,max(date) as date from ress group by time
      

  3.   

    先分組,然後從分組中選出最大的日期,也說是你說的最後一個日期,
    select time,max(date) as date from ress group by time
      

  4.   

    YourInsertTable是你要存到的另一个表,在语句执行后生成:Select time,Max(date) As date Into YourInsertTable From ress Group By time
      

  5.   

    若已经存在YourInsertTable这表,则:Insert Into YourInsertTable(mtime,mdate) Select mtime,Max(mdate) As mdate From ress Group By mtime
      

  6.   

    簡單简单写法insert into Table
    select top 1 time from ress order by time desc