[SQL-CVS] r3525 - SQLObject/branches/0.9/sqlobject/sqlite
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
|
From: <sub...@co...> - 2008-07-24 16:04:34
|
Author: phd
Date: 2008-07-24 10:04:25 -0600 (Thu, 24 Jul 2008)
New Revision: 3525
Modified:
SQLObject/branches/0.9/sqlobject/sqlite/sqliteconnection.py
Log:
Fixed the bug 2009801: sqlobject-admin fails to process sqlite database with enums.
Modified: SQLObject/branches/0.9/sqlobject/sqlite/sqliteconnection.py
===================================================================
--- SQLObject/branches/0.9/sqlobject/sqlite/sqliteconnection.py 2008-07-23 15:41:06 UTC (rev 3524)
+++ SQLObject/branches/0.9/sqlobject/sqlite/sqliteconnection.py 2008-07-24 16:04:25 UTC (rev 3525)
@@ -308,9 +308,9 @@
raise ValueError('The table %s ws not found in the database. Load failed.' % tableName)
colData = colData[0].split('(', 1)[1].strip()[:-2]
while colData.find('(') > -1:
- st = colData.find('(')
- en = colData.find(')')
- colData = colData[:st] + colData[en+1:]
+ start = colData.find('(')
+ end = colData.find(')', start)
+ colData = colData[:start] + colData[end+1:]
results = []
for colDesc in colData.split(','):
parts = colDesc.strip().split(' ', 2)
|