diff options
Diffstat (limited to 'sql')
| -rw-r--r-- | sql/dawn.sql | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sql/dawn.sql b/sql/dawn.sql index f9cf3af7..3f38a4a2 100644 --- a/sql/dawn.sql +++ b/sql/dawn.sql @@ -34,8 +34,6 @@ CREATE TYPE protection AS ENUM('Buyer', 'Seller'); CREATE TYPE call_notice AS ENUM('24H', '48H', '3D', '4D', '5D', '6D', '1W', '8D', '9D', '10D', '2W', '1M', '2M'); -CREATE TYPE source AS ENUM('Broker','IDC','S&P','BVAL','PRICESERVE','PRICINGDIRECT','MARKIT','PB','Reuters','Manager') - CREATE TABLE counterparties(code varchar(12) primary key, name text, city text, @@ -269,8 +267,8 @@ CREATE TABLE external_marks( identifier varchar(12) REFERENCES securities ON UPDATE CASCADE, date date, mark float, - source source, - PRIMARY KEY (identifier, date)); + source text, + PRIMARY KEY (identifier, date, source)); CREATE OR REPLACE function list_marks(p_date date, include_unsettled boolean DEFAULT False) RETURNS TABLE(identifier varchar(12), price float) AS $$ |
