mirror of
https://github.com/c9s/bbgo.git
synced 2024-11-10 09:11:55 +00:00
make order id unique
This commit is contained in:
parent
8693bbbd24
commit
9f532be5a1
|
@ -1,7 +1,7 @@
|
|||
-- +goose Up
|
||||
CREATE INDEX orders_symbol ON orders (exchange, symbol);
|
||||
CREATE INDEX orders_id_symbol ON orders(exchange, order_id, symbol);
|
||||
CREATE UNIQUE INDEX orders_order_id ON orders (order_id, exchange);
|
||||
|
||||
-- +goose Down
|
||||
DROP INDEX orders_symbol ON orders;
|
||||
DROP INDEX orders_id_symbol ON orders;
|
||||
DROP INDEX orders_order_id ON orders;
|
||||
|
|
Loading…
Reference in New Issue
Block a user