mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-25 16:25:16 +00:00
migrations: add index on positions table
This commit is contained in:
parent
17d3097e06
commit
744ca57c71
10
migrations/mysql/20240918132534_add_position_index.sql
Normal file
10
migrations/mysql/20240918132534_add_position_index.sql
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
-- +up
|
||||||
|
-- +begin
|
||||||
|
CREATE INDEX positions_traded_at ON positions (traded_at, profit);
|
||||||
|
-- +end
|
||||||
|
|
||||||
|
-- +down
|
||||||
|
|
||||||
|
-- +begin
|
||||||
|
DROP INDEX positions_traded_at ON positions;
|
||||||
|
-- +end
|
10
migrations/sqlite3/20240918132534_add_position_index.sql
Normal file
10
migrations/sqlite3/20240918132534_add_position_index.sql
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
-- +up
|
||||||
|
-- +begin
|
||||||
|
CREATE INDEX positions_traded_at ON positions (traded_at, profit);
|
||||||
|
-- +end
|
||||||
|
|
||||||
|
-- +down
|
||||||
|
|
||||||
|
-- +begin
|
||||||
|
DROP INDEX positions_traded_at;
|
||||||
|
-- +end
|
Loading…
Reference in New Issue
Block a user