select top 10  * from table

解决方案 »

  1.   

    有两种办法:
    1.
    select top 10 * from tablename where ...
    select top 10 col1,col2,...coln from tablename where...
    2.
    set rowcount 10
    select * from tablename where ...
    select col1,col2,...coln from tablename where...
    set rowcount 0
      

  2.   

    select top 10  * from table
     我就是这么写的压。
      

  3.   

    to:supsuccess(火气不小)
    set rowcount 10 可以运行,但是必须写到存储过程中去,得修改程序。
    可不可以解释为什么top 10 不支持呢?
      

  4.   

    Server: Msg 170, Level 15, State 1, Line 1
    Line 1: Incorrect syntax near '10'.
      

  5.   

    sql 7.0.这个没有关系的,因为我发觉在同一台服务器上,有的数据库可以,有的则不可以。
      

  6.   

    错误提示:语法问题,写出你完整得SQL语句,就像此贴得标题,就错了:)