]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
fix for when default is zero
authorJonathan Ellis <jbellis@gmail.com>
Mon, 31 Jul 2006 21:00:48 +0000 (21:00 +0000)
committerJonathan Ellis <jbellis@gmail.com>
Mon, 31 Jul 2006 21:00:48 +0000 (21:00 +0000)
lib/sqlalchemy/databases/sqlite.py

index 361705b71691bc3b2ee16e8c5515699e5eb3b93b..b68bf99a726bad679abf3021a030f9ab44b7bea2 100644 (file)
@@ -178,7 +178,7 @@ class SQLiteDialect(ansisql.ANSIDialect):
                 break
             #print "row! " + repr(row)
             found_table = True
-            (name, type, nullable, has_default, primary_key) = (row[1], row[2].upper(), not row[3], row[4], row[5])
+            (name, type, nullable, has_default, primary_key) = (row[1], row[2].upper(), not row[3], row[4] is not None, row[5])
             
             match = re.match(r'(\w+)(\(.*?\))?', type)
             coltype = match.group(1)