diff options
Diffstat (limited to 'python/facility_update.py')
| -rw-r--r-- | python/facility_update.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/python/facility_update.py b/python/facility_update.py index 9d2f234a..95d38064 100644 --- a/python/facility_update.py +++ b/python/facility_update.py @@ -52,10 +52,10 @@ with open( filename, "wb") as fh: with open( filename, "r") as fh:
reader = csv.reader(fh)
reader.next()
+ c = common.conn.cursor()
sqlstring = "INSERT INTO markit_facility VALUES( {0} )".format( ",".join(["%s"] * 13))
for line in reader:
newline = [convertToNone(v) for v in line]
- common.cursor.execute(sqlstring, newline)
+ c.execute(sqlstring, newline)
common.conn.commit()
-common.cursor.close()
common.conn.close()
|
