Need to delete first n rows at a time <B>FROM A SET OF ROWS </B> that are returned, I am not able to use ROW_NUMBER() OVER() in a delete statement..
Eg.
delete from TableName where col1 > 10 and col2 <20
I wanna delete the first row from the result set returned by this delete statement.
I tried with,
delete from TableName where col1 > 10 and col2 <20 and ROW_NUMBER() OVER() < 2
but it fails..
thanks
Shefu