diff options
| -rw-r--r-- | python/collateral/common.py | 8 | ||||
| -rw-r--r-- | python/strat_cash_realloc.py | 2 |
2 files changed, 2 insertions, 8 deletions
diff --git a/python/collateral/common.py b/python/collateral/common.py index b4c83197..1cecbd9f 100644 --- a/python/collateral/common.py +++ b/python/collateral/common.py @@ -33,13 +33,7 @@ CASH_STRATEGY_MAPPING = { "MACCDSCSH": ["HEDGE_MAC", "CASH_BASIS"], "CVECSH": ["SER_ITRXCURVE", "SER_IGCURVE", "SER_HYCURVE", "XCURVE"], "CLOCDSCSH": ["HEDGE_CLO", "M_CLO_BB20"], - "M_CSH_CASH": [ - "CRT_LD", - "CRT_LD_JNR", - "CRT_SD", - "MTG_FP", - "MTG_LMG", - ], + "M_CSH_CASH": ["CRT_LD", "CRT_LD_JNR", "CRT_SD", "MTG_FP", "MTG_LMG", "M_MTG_FP"], } STRATEGY_CASH_MAPPING = {e: k for k, v in CASH_STRATEGY_MAPPING.items() for e in v} diff --git a/python/strat_cash_realloc.py b/python/strat_cash_realloc.py index 8a6d96b8..c5c7157a 100644 --- a/python/strat_cash_realloc.py +++ b/python/strat_cash_realloc.py @@ -30,7 +30,7 @@ def generate_csv(date, conn): headers = HEADERS["wire"] with conn.cursor() as c, conn.cursor() as d: c.execute( - "SELECT vr.*, accounts2.custodian, accounts2.cp_code, pfm.folder AS dirty_strat FROM (SELECT sum(endqty) AS endqty, port, strat, custacctname, invid FROM valuation_reports v WHERE periodenddate ='2022-05-19' AND fund='BOWDST' AND invid IN ('USD', 'EUR') AND port NOT IN ('GFS_HELPER_BUSINESS_UNIT', 'CASH') GROUP BY (port, strat,custacctname, invid) HAVING sum(endqty) !=0) vr LEFT JOIN accounts2 ON custacctname=cash_account LEFT JOIN portfolio_folder_mapping pfm ON vr.strat::text=pfm.clean_folder where pfm.folder is not NULL;", + "SELECT vr.*, accounts2.custodian, accounts2.cp_code, pfm.folder AS dirty_strat FROM (SELECT sum(endqty) AS endqty, port, strat, custacctname, invid FROM valuation_reports v WHERE periodenddate =%s AND fund='BOWDST' AND invid IN ('USD', 'EUR') AND port NOT IN ('GFS_HELPER_BUSINESS_UNIT', 'CASH') GROUP BY (port, strat,custacctname, invid) HAVING sum(endqty) !=0) vr LEFT JOIN accounts2 ON custacctname=cash_account LEFT JOIN portfolio_folder_mapping pfm ON vr.strat::text=pfm.clean_folder where pfm.folder is not NULL;", (date,), ) trades = [] |
