Results Navigation
Use the controls below to drill down into these results
|
|
Jun
06
2010
|
British Sprint Triathlon Championships (750m swim/20k cycle/5k 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=956)
, spt10771 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=10771 And Splits.Duration Is Not NULL), spt10772 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=10772 And Splits.Duration Is Not NULL), spt10773 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=10773 And Splits.Duration Is Not NULL), spt10774 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=10774 And Splits.Duration Is Not NULL), spt10775 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=10775 And Splits.Duration Is Not NULL), spt11500 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=11500 And Splits.Duration Is Not NULL), spt10776 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=10776 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, spt10771.Duration AS [Splt_10771]
, spt10772.Duration AS [Splt_10772]
, spt10773.Duration AS [Splt_10773]
, spt10774.Duration AS [Splt_10774]
, spt10775.Duration AS [Splt_10775]
, spt11500.Duration AS [Splt_11500]
, spt10776.Duration AS [Splt_10776]
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 spt10771 WITH (NOLOCK) ON spt10771.ResultId=Results.ResultId
LEFT OUTER JOIN spt10772 WITH (NOLOCK) ON spt10772.ResultId=Results.ResultId
LEFT OUTER JOIN spt10773 WITH (NOLOCK) ON spt10773.ResultId=Results.ResultId
LEFT OUTER JOIN spt10774 WITH (NOLOCK) ON spt10774.ResultId=Results.ResultId
LEFT OUTER JOIN spt10775 WITH (NOLOCK) ON spt10775.ResultId=Results.ResultId
LEFT OUTER JOIN spt11500 WITH (NOLOCK) ON spt11500.ResultId=Results.ResultId
LEFT OUTER JOIN spt10776 WITH (NOLOCK) ON spt10776.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
|