Update of /cvsroot/sqlobject/SQLObject/SQLObject
In directory sc8-pr-cvs1:/tmp/cvs-serv11549/SQLObject
Modified Files:
DBConnection.py
Log Message:
Improved SQLite support (untested!)
Index: DBConnection.py
===================================================================
RCS file: /cvsroot/sqlobject/SQLObject/SQLObject/DBConnection.py,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** DBConnection.py 31 Mar 2003 05:51:28 -0000 1.9
--- DBConnection.py 2 Apr 2003 18:19:26 -0000 1.10
***************
*** 402,406 ****
def createIDColumn(self, soClass):
! return '%s INT NOT NULL' % soClass._idName
def joinSQLType(self):
--- 402,406 ----
def createIDColumn(self, soClass):
! return '%s INTEGER PRIMARY KEY' % soClass._idName
def joinSQLType(self):
***************
*** 408,411 ****
def tableExists(self, tableName):
! # @@: obvious not implemented
! return False
--- 408,412 ----
def tableExists(self, tableName):
! result = self.queryOne("SELECT tbl_name FROM sqlite_master WHERE type='table' AND tbl_name = '%s'" % tableName)
! # turn it into a boolean:
! return not not result
|