Added index and foreign key support to server_populations table.
This commit is contained in:
parent
dd68cbdeb6
commit
5df2d7e3fd
@ -76,6 +76,6 @@ type ServerPopulation struct {
|
||||
ID int
|
||||
Timestamp time.Time
|
||||
Players int
|
||||
ServerID int
|
||||
ServerID int `sql:"index;type:integer REFERENCES servers(id) ON DELETE CASCADE ON UPDATE CASCADE"`
|
||||
Server Server
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user