如题

解决方案 »

  1.   

    SELECT TOP 1 * FROM TABLE ORDER BY ID DESC
      

  2.   

    排序的依据是哪个字段?
    假设该字段名为time
    select top 1 * from yourTable order by time desc
      

  3.   

    SELECT TOP 1 * FROM TABLENAME ORDER FIELDNAME DESC
    把TABLENAME改成你的表名,FIELDName改成你要排序的字段名。
      

  4.   

    select top 1 * from [表名] order by [排序字段名] desc
      

  5.   

    最好的方法是用游标来实现..
    想取表中的哪一行就取哪一行...declare cursor_Name cursor scroll for 
          select * from 表
          order by 1
    open cursor_Name
    fetch last from cursor_Name
    close cursor_Name
    deallocate cursor_Name