• What have you tried?

    a couple hints.

    Use the case statement, wrapped in Min, or Max

    Group by Col 1, Col 2

    Check this out.

    http://www.sqlservercentral.com/articles/Best+Practices/61537/[/url]