aboutsummaryrefslogtreecommitdiffstats
path: root/python/upload_bbh_trades.py
diff options
context:
space:
mode:
Diffstat (limited to 'python/upload_bbh_trades.py')
-rw-r--r--python/upload_bbh_trades.py15
1 files changed, 3 insertions, 12 deletions
diff --git a/python/upload_bbh_trades.py b/python/upload_bbh_trades.py
index 2f9fa0b8..d827e3ee 100644
--- a/python/upload_bbh_trades.py
+++ b/python/upload_bbh_trades.py
@@ -56,18 +56,9 @@ if __name__ == "__main__":
],
)
try:
- try:
- df.to_sql(
- "bbh_bond_upload", dawn_engine, index=False, if_exists="append"
- )
- except IntegrityError:
- conn.rollback()
- df["Client Reference Number"] = df["Client Reference Number"] + "-U"
- df = pd.read_sql_query(
- "SELECT * FROM bbh_bond_upload where tradeid=%s",
- dawn_engine,
- params=(obj["tradeid"],),
- )
+ df.to_sql(
+ "bbh_bond_upload", dawn_engine, index=False, if_exists="append"
+ )
except IntegrityError:
conn.rollback()
else: