? README
Index: TEST_PyGreSQL_dbapi20.py
===================================================================
RCS file: /usr/pubcvs/pygresql/module/TEST_PyGreSQL_dbapi20.py,v
retrieving revision 1.4
diff -u -p -u -r1.4 TEST_PyGreSQL_dbapi20.py
--- TEST_PyGreSQL_dbapi20.py	28 May 2006 19:18:50 -0000	1.4
+++ TEST_PyGreSQL_dbapi20.py	21 Sep 2006 15:11:58 -0000
@@ -12,7 +12,7 @@ dbname = 'dbapi20_test'
 dbhost = None
 dbport = 5432
 
-class test_Psycopg(dbapi20.DatabaseAPI20Test):
+class test_PyGreSQL(dbapi20.DatabaseAPI20Test):
     driver = pgdb
     connect_args = ()
     connect_kw_args = {'dsn': ':' + dbname}
Index: pgdb.py
===================================================================
RCS file: /usr/pubcvs/pygresql/module/pgdb.py,v
retrieving revision 1.34
diff -u -p -u -r1.34 pgdb.py
--- pgdb.py	30 Jul 2006 23:23:50 -0000	1.34
+++ pgdb.py	21 Sep 2006 15:11:58 -0000
@@ -153,6 +153,20 @@ class pgdbCursor:
 		self.arraysize = 1
 		self.lastrowid = None
 
+	def row_factory(self, row):
+		"""You can overwrite this with a custom row factory
+			e.g. a dict_factory
+
+			cursor = pgdbCursor(src, cache)
+			def cursor.row_factory(caller, row):
+				d = {}
+				for idx, col in enumerate(caller.description):
+					d[col[0]] = row[idx]
+				return d
+		"""
+
+		return row
+
 	def close(self):
 		self.__source.close()
 		self.description = None
@@ -244,7 +258,7 @@ class pgdbCursor:
 						r[i]
 					)
 				)
-			result.append(row)
+			result.append(self.row_factory(row))
 		return result
 
 	def nextset(self):
