diff options
Diffstat (limited to 'createdb.py')
| -rw-r--r-- | createdb.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/createdb.py b/createdb.py index 7f50807..7ec9cd0 100644 --- a/createdb.py +++ b/createdb.py @@ -9,9 +9,7 @@ if __name__ == "__main__": required=True) args = arg_parser.parse_args() - conn = sqlite3.connect(args.database) - c = conn.cursor() + conn = sqlite3.connect(args.database, detect_types=sqlite3.PARSE_DECLTYPES) schema = open(args.schema) - c.executescript( schema.read() ) - conn.commit() - c.close() + conn.executescript( schema.read() ) + conn.close() |
