From e9bd81f3529ced6038762de0b0b543d09319e9c7 Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Thu, 21 Aug 2025 15:30:08 -0400 Subject: [PATCH] new table to store target price components --- tables/core_target.pg.sql | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 tables/core_target.pg.sql diff --git a/tables/core_target.pg.sql b/tables/core_target.pg.sql new file mode 100644 index 0000000..4bda31f --- /dev/null +++ b/tables/core_target.pg.sql @@ -0,0 +1,16 @@ + +DROP TABLE IF EXISTS pricequote.core_target; + +CREATE TABLE pricequote.core_target ( + compset TEXT NOT NULL, + stlc TEXT NOT NULL, + floor NUMERIC NOT NULL, + options JSONB NOT NULL, + PRIMARY KEY (stlc) +); + +GRANT SELECT, INSERT, UPDATE, DELETE ON pricequote.target_prices TO PUBLIC; + +DROP TABLE IF EXISTS import.core_target; + +CREATE TABLE import.core_target AS (SELECT * FROM pricequote.core_target);