Query Question

  • Here's another approach...

    SELECT Pl.PlayerFirst AS Player,

    COUNT(ALL Sc.Finished) AS Events,

    SUM(CASE

    WHEN Sc.Finished = '1' THEN 1

    ELSE 0

    END) AS Wins

    FROM Player Pl

    LEFT OUTER JOIN ScoreCard Sc

    ON Sc.PlayerID = Pl.PlayerID

    GROUP BY Pl.PlayerFirst

    ORDER BY Pl.PlayerFirst

  • This also executed successfully with the same results, but less coding. Thanks for your input.

Viewing 2 posts - 16 through 16 (of 16 total)

You must be logged in to reply to this topic. Login to reply