aboutsummaryrefslogtreecommitdiffstats
path: root/python/quote_parsing
diff options
context:
space:
mode:
Diffstat (limited to 'python/quote_parsing')
-rw-r--r--python/quote_parsing/parse_emails.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/python/quote_parsing/parse_emails.py b/python/quote_parsing/parse_emails.py
index bc1c2c37..ff883cb7 100644
--- a/python/quote_parsing/parse_emails.py
+++ b/python/quote_parsing/parse_emails.py
@@ -910,8 +910,10 @@ def write_todb(swaption_stack, index_data, conn):
)
cols = [sql.Identifier(e) for e in (*swaption_stack.columns, "ref_id")]
sql_quotes = sql.SQL(
- "INSERT INTO swaption_quotes({}) VALUES {} ON CONFLICT DO NOTHING"
- ).format(sql.SQL(", ").join(cols), [sql.Placeholder()] * len(cols))
+ "INSERT INTO swaption_quotes({}) VALUES ({}) ON CONFLICT DO NOTHING"
+ ).format(
+ sql.SQL(", ").join(cols), sql.SQL(",").join([sql.Placeholder()] * len(cols))
+ )
index_data["expiry"] = pd.to_datetime(index_data.expiry)
with conn.cursor() as c:
for t in index_data.itertuples(index=False):