Public Access
64 lines
1.0 KiB
Plaintext
64 lines
1.0 KiB
Plaintext
erDiagram
|
|
journey||--|{routesegments: "consists of"
|
|
routesegments||--||segment: "sorts"
|
|
segment||--|{departure: "consists of"
|
|
departure}|--|{station: "originates from"
|
|
departure}|--||vehicle: uses
|
|
vehicle||..|{line: "shared data"
|
|
segment}|--||vehicle: uses
|
|
stationlines}|..||station: "general connections"
|
|
stationlines}|..||line: groups
|
|
|
|
|
|
journey {
|
|
int id PK
|
|
string startstation
|
|
string endstation
|
|
}
|
|
routesegments {
|
|
int id PK
|
|
int journey FK
|
|
int segment FK
|
|
int segmentorder
|
|
}
|
|
segment {
|
|
int id PK
|
|
string ref
|
|
int startid FK
|
|
int endid FK
|
|
string vehicleid FK
|
|
}
|
|
departure {
|
|
int id PK
|
|
string ref
|
|
string direction
|
|
string vehicle FK
|
|
string vehiclename
|
|
string station FK
|
|
string stationname
|
|
string arrivaltime
|
|
string departuretime
|
|
}
|
|
station {
|
|
string id PK
|
|
string name
|
|
}
|
|
stationlines {
|
|
int id PK
|
|
string stationid FK
|
|
string lineid FK
|
|
}
|
|
vehicle {
|
|
string vehicleid PK
|
|
string name
|
|
string line FK
|
|
}
|
|
line {
|
|
string lineid PK
|
|
string name
|
|
string mode
|
|
string destination
|
|
string direction
|
|
string fgcolor
|
|
string bgcolor
|
|
} |