Results Navigation
Use the controls below to drill down into these results
|
|
Jul
04
2010
|
Cowman 2010 (1900m swim/92k cycle/21k run)
|
Rate this information
| Not rated |
| No feedback available for this area |
WITH resultSet AS (SELECT Results.ResultId FROM Results WITH (NOLOCK) WHERE Results.RaceId=957)
, spt10777 AS (SELECT Splits.ResultId, Splits.SplitId, Splits.Duration, Splits.RaceSplitId, Splits.Placing AS SplitRank FROM Splits WITH (NOLOCK) INNER JOIN ResultSet WITH (NOLOCK) ON resultSet.ResultId=Splits.ResultId WHERE Splits.RaceSplitId=10777 And Splits.Duration Is Not NULL), spt10778 AS (SELECT Splits.ResultId, Splits.SplitId, Splits.Duration, Splits.RaceSplitId, Splits.Placing AS SplitRank FROM Splits WITH (NOLOCK) INNER JOIN ResultSet WITH (NOLOCK) ON resultSet.ResultId=Splits.ResultId WHERE Splits.RaceSplitId=10778 And Splits.Duration Is Not NULL), spt10779 AS (SELECT Splits.ResultId, Splits.SplitId, Splits.Duration, Splits.RaceSplitId, Splits.Placing AS SplitRank FROM Splits WITH (NOLOCK) INNER JOIN ResultSet WITH (NOLOCK) ON resultSet.ResultId=Splits.ResultId WHERE Splits.RaceSplitId=10779 And Splits.Duration Is Not NULL), spt10780 AS (SELECT Splits.ResultId, Splits.SplitId, Splits.Duration, Splits.RaceSplitId, Splits.Placing AS SplitRank FROM Splits WITH (NOLOCK) INNER JOIN ResultSet WITH (NOLOCK) ON resultSet.ResultId=Splits.ResultId WHERE Splits.RaceSplitId=10780 And Splits.Duration Is Not NULL), spt10781 AS (SELECT Splits.ResultId, Splits.SplitId, Splits.Duration, Splits.RaceSplitId, Splits.Placing AS SplitRank FROM Splits WITH (NOLOCK) INNER JOIN ResultSet WITH (NOLOCK) ON resultSet.ResultId=Splits.ResultId WHERE Splits.RaceSplitId=10781 And Splits.Duration Is Not NULL), spt10782 AS (SELECT Splits.ResultId, Splits.SplitId, Splits.Duration, Splits.RaceSplitId, Splits.Placing AS SplitRank FROM Splits WITH (NOLOCK) INNER JOIN ResultSet WITH (NOLOCK) ON resultSet.ResultId=Splits.ResultId WHERE Splits.RaceSplitId=10782 And Splits.Duration Is Not NULL)
SELECT
ROW_NUMBER() OVER( ORDER BY CASE WHEN Placing IS NULL THEN 1 ELSE 0 END, Placing ASC
, CASE WHEN Finish IS NULL THEN 1 ELSE 0 END, Finish ASC
) AS RowNumber ,ISNULL(Results.Status,'') AS Status
,ISNULL(Results.Laps,0) AS Laps
,Results.Firstname
,Results.Lastname
,Results.Firstname + ' ' + Results.Lastname AS Competitor
,Results.RaceNumber
,ISNULL(Results.Category, '') AS Category
,ISNULL(Results.Team,'') AS Team
,ISNULL(Results.Club, '') AS Club
,Results.Gender
,Gender.Keyword AS GenderStr
,Results.ResultId
,Results.Placing
,Results.RaceId
,Events.EventManagerId
,ISNULL(Results.Notes,'') AS Notes
,'' AS StaticData, spt10777.Duration AS [Splt_10777]
, spt10778.Duration AS [Splt_10778]
, spt10779.Duration AS [Splt_10779]
, spt10780.Duration AS [Splt_10780]
, spt10781.Duration AS [Splt_10781]
, spt10782.Duration AS [Splt_10782]
FROM Results WITH (NOLOCK) INNER JOIN Races WITH (NOLOCK) ON Races.RaceId=Results.RaceId INNER JOIN resultSet WITH (NOLOCK) ON resultSet.ResultId=Results.ResultId INNER JOIN Events WITH (NOLOCK) ON Events.EventId=Races.EventId
LEFT OUTER JOIN Keywords Gender WITH (NOLOCK) ON Gender.KeywordId=Results.Gender AND Gender.Language='English' AND Gender.GroupName='Gender'
LEFT OUTER JOIN spt10777 WITH (NOLOCK) ON spt10777.ResultId=Results.ResultId
LEFT OUTER JOIN spt10778 WITH (NOLOCK) ON spt10778.ResultId=Results.ResultId
LEFT OUTER JOIN spt10779 WITH (NOLOCK) ON spt10779.ResultId=Results.ResultId
LEFT OUTER JOIN spt10780 WITH (NOLOCK) ON spt10780.ResultId=Results.ResultId
LEFT OUTER JOIN spt10781 WITH (NOLOCK) ON spt10781.ResultId=Results.ResultId
LEFT OUTER JOIN spt10782 WITH (NOLOCK) ON spt10782.ResultId=Results.ResultId
ORDER BY CASE WHEN Placing IS NULL THEN 1 ELSE 0 END, Placing ASC
, CASE WHEN Finish IS NULL THEN 1 ELSE 0 END, Finish ASC
|