diff options
Diffstat (limited to 'python/intex/load_indicative.py')
| -rw-r--r-- | python/intex/load_indicative.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/python/intex/load_indicative.py b/python/intex/load_indicative.py index d8d87913..d2778a3a 100644 --- a/python/intex/load_indicative.py +++ b/python/intex/load_indicative.py @@ -35,7 +35,11 @@ def upload_cusip_data(conn, filename): with conn.cursor() as c: c.execute("SELECT \"Latest Update\" FROM clo_universe " \ "WHERE dealname = %s ORDER BY \"Latest Update\" DESC", (dealname,)) - dealupdate[dealname] = c.fetchone()[0] + try: + dealupdate[dealname] = c.fetchone()[0] + except TypeError: + logging.error('deal:{0} not in database'.format(dealname)) + continue sqlstring = "SELECT updatedate FROM latest_cusip_universe WHERE cusip = %s" with conn.cursor() as c: |
