DELETE TOP syntax
Posted on 2003-10-22
I was trying to do something like
DELETE TOP 3 FROM tblName
But the query anaylzer says invalid keyword by the word TOP.
I was going to use the SET ROWCOUNT method, such as
SET ROWCOUNT = 3
DELETE FROM tblName
But SQL Books Online suggested that you should replace any SET ROWCOUNT commands with the appropriate TOP version for any DELETE, INSERT, UPDATE.
So according to it, there is a DELETE TOP command, but I can't seem to find a reference anywhere on what the syntax is. Does anyone know if this is a valid command, and if so what the syntax is? By the way I'm using MS SQL 2000, thanks.