Spaces:
Runtime error
Runtime error
File size: 2,685 Bytes
842269e |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 |
from sqlalchemy import Column, Float, Integer, String
from sqlalchemy.ext.declarative import declarative_base
# from . import database
import database
class RacePace(database.Base):
__tablename__ = "race_pace"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
year = Column(Integer)
event = Column(String)
session = Column(String)
Driver = Column(String)
LapTime = Column(Float)
Diff = Column(Float)
Team = Column(String)
fill = Column(String)
class TopSpeed(database.Base):
__tablename__ = "top_speed"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
year = Column(Integer)
event = Column(String)
session = Column(String)
driver = Column(String)
top_speed = Column(Integer)
compound = Column(String)
team = Column(String)
fill = Column(String)
class Overtakes(database.Base):
__tablename__ = "overtakes"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
year = Column(Integer)
event = Column(String)
driver = Column(String)
overtakes = Column(Integer)
overtaken = Column(Integer)
class FastestLap(database.Base):
__tablename__ = "fastest_lap"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
year = Column(Integer)
event = Column(String)
session = Column(String)
driver = Column(String)
lap_time = Column(Float)
diff = Column(Float)
team = Column(String)
fill = Column(String)
class DriverStandings(database.Base):
__tablename__ = "driver_standings"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
year = Column(Integer)
driver = Column(String)
points = Column(Integer)
car = Column(String)
fill = Column(String)
class AvailableYears(database.Base):
__tablename__ = "available_years"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
year = Column(Integer)
class AvailableEvents(database.Base):
__tablename__ = "available_events"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
year = Column(Integer)
event = Column(String)
class AvailableSessions(database.Base):
__tablename__ = "available_sessions"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
year = Column(Integer)
event = Column(String)
session = Column(String)
class AvailableDrivers(database.Base):
__tablename__ = "available_drivers"
id = Column(Integer, primary_key=True, autoincrement=True, index=True)
color = Column(String)
label = Column(String)
value = Column(String)
|