Skip to content
Prev Previous commit
Next Next commit
Minor spacing fixes.
  • Loading branch information
musically-ut authored Apr 11, 2019
commit 2b39ef6e65caad859eb3c4f7cd698e098de2b309
10 changes: 5 additions & 5 deletions load_into_pg.py
Original file line number Diff line number Diff line change
Expand Up @@ -272,10 +272,10 @@ def moveTableToSchema(table, schemaName, dbConnectionParam):
with pg.connect(dbConnectionParam) as conn:
with conn.cursor() as cur:
# create the schema
cur.execute('CREATE SCHEMA IF NOT EXISTS '+schemaName+';')
cur.execute('CREATE SCHEMA IF NOT EXISTS ' + schemaName + ';')
conn.commit()
# move the table to the right schema
cur.execute('ALTER TABLE '+table+' SET SCHEMA '+schemaName+';')
cur.execute('ALTER TABLE '+table+' SET SCHEMA ' + schemaName + ';')
conn.commit()
except pg.Error as e:
six.print_("Error in dealing with the database.", file=sys.stderr)
Expand Down Expand Up @@ -305,7 +305,7 @@ def moveTableToSchema(table, schemaName, dbConnectionParam):
)

parser.add_argument( '-s', '--so-project'
, help = 'stackexchange project to load.'
, help = 'StackExchange project to load.'
, default = None
)

Expand All @@ -315,8 +315,8 @@ def moveTableToSchema(table, schemaName, dbConnectionParam):
)

parser.add_argument( '-k', '--keep-archive'
, help = 'should we keep the downloaded archive.'
, action = 'store_true'
, help = 'Will preserve the downloaded archive instead of deleting it.'
, action = 'store_true'
, default = False
)

Expand Down