• Steven Willis (3/5/2013)


    Another old habit to break if you are using SQL2008 or greater is to avoid GROUP BY when all you really need is an aggregated column value.

    ...

    You can still use GROUP BY of course if you need to group the portfolios themselves but just to do sums or counts (or min or max, etc) the OVER() clause makes things a lot easier.

     

    Out of curiosity, why avoid GROUP BY? Do you suggest this only because it is "easier"?

    ______________________________________________________________________________________________
    Forum posting etiquette.[/url] Get your answers faster.