equal
deleted
inserted
replaced
48 print 'creating necessary tables into the system source' |
48 print 'creating necessary tables into the system source' |
49 source = sourcescfg['system'] |
49 source = sourcescfg['system'] |
50 driver = source['db-driver'] |
50 driver = source['db-driver'] |
51 sqlcnx = repo.system_source.get_connection() |
51 sqlcnx = repo.system_source.get_connection() |
52 sqlcursor = sqlcnx.cursor() |
52 sqlcursor = sqlcnx.cursor() |
53 def execute(sql, args=None): |
53 execute = sqlcursor.execute |
54 repo.system_source.doexec(sqlcursor, sql, args) |
|
55 if drop: |
54 if drop: |
56 dropsql = sqldropschema(schema, driver) |
55 dropsql = sqldropschema(schema, driver) |
57 try: |
56 try: |
58 sqlexec(dropsql, execute) |
57 sqlexec(dropsql, execute) |
59 except Exception, ex: |
58 except Exception, ex: |