I'm using sql server 2008 R2.
I was looking at a sql server query and I noticed that it was using a notation that looked like this.
This is a snippet from the full query. I noticed that a variable was declared and then some sql statements where enclosed in parentheses and assigned to that variable.
What is the technical name for this style or technique?
Do you have a link to a website or book that covers writing a query in this fashion.
What are the pros and cons or writing a sql query this way?