Changeset 3330

Show
Ignore:
Timestamp:
08/23/07 17:48:03 (1 year ago)
Author:
ed
Message:

Merged my changes with the ones John just committed.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/dabo/db/dbPostgreSQL.py

    r3329 r3330  
    6868        tables = [] 
    6969        for record in rs: 
    70             tables.append(record[0]) 
     70            tables.append(record["tablename"]) 
    7171        return tuple(tables) 
    7272 
     
    7474    def getTableRecordCount(self, tableName, cursor): 
    7575        cursor.execute("select count(*) as ncount from %s" % tableName) 
    76         return cursor.getDataSet()[0][0
     76        return cursor.getDataSet()[0]["ncount"
    7777 
    7878 
     
    107107        else: 
    108108            #thestr = rs2[0][3] 
    109             #thePKFieldName = thestr[thestr.find("(") + 1: thestr.find(")")].split(", ") 
    110             #thePKFieldName = rs2[0][3] 
    111109            thePKFieldName = rs2[0]['column_name'] 
    112110         
    113111        fields = [] 
    114112        for r in rs: 
    115             name = r['attname'] 
    116             #fldType =r[2] 
    117             fldType =r['typname'] 
     113            name = r["attname"] 
     114            fldType =r["typname"] 
    118115            pk = False 
    119116            if thePKFieldName is not None: