2015-07-02

TOP not only for SELECT

I actually never considered the case that the TOP clause in SQL can be used for other tings than SELECT. But is it really a realistic use-case?

I had to dig deep in my memory archive but I do remember a few instances where I have used TOP in sub-SELECTs in order to control how an update or delete behaved. So while it is not the most common scenario I think it is definitely handy. You can read more about TOP all over the place here.

No comments:

Post a Comment