I was trying to understand how to use the WITH clause and the purpose of the WITH clause.
WITH
All I understood was, the WITH clause was a replacement for normal sub-queries.
Can anyone explain this to me with a small example in detail ?