Skip to main content

Circuits

[dbo.circuits]​

Column nameKeyData typeAllow NULLsDefaultDescription
circuitIdPrimary KeyINT☐
circuitRefVARCHAR(255)☐Unique circuit identifier
nameVARCHAR(255)☐Circuit name
altINT☑Altitude (metres)
urlVARCHAR(255)☐Circuit Wikipedia page
locationIDINT☑Foreign key links to locations
countryIDINT☑Foreign Key link to countries
circuitDirectionIDINT☑Foreign key link to circuitDirection
circuitTypeIDINT☑Foreign key link to circuitType

Table Relationships​

Circuits

Where Used​

Where is this table referenced and what columns are used? The below table shows that information.

[dbo.circuits]​

Parent_schemaNameParent_tableNameParent_columnNameSchematablecolumnconstraint_name
dbocircuitscircuitIddbocircuitMapcircuitIdFK_circuitMap_circuitId
dbocircuitscircuitIddboracescircuitIdFK_Races_CircuitID

Example Query​

SELECT 
[circuitId]
,[circuitRef]
,[name]
,[location]
,[country]
,[alt]
,[url]
FROM
[dbo].[circuits]
WHERE
circuitRef ='spa'
AND active = 1

Example Output​

circuitIdcircuitRefnamealturllocationIDcountryIDcircuitDirectionIDcircuitTypeID
1albert_parkAlbert Park Grand Prix Circuit10http://en.wikipedia.org/wiki/Melbourne_Grand_Prix_Circuit40211
2sepangSepang International Circuit18http://en.wikipedia.org/wiki/Sepang_International_Circuit311712