in selectall, close the db connection when we are finished
authorTony Mack <tmack@cs.princeton.edu>
Tue, 31 Mar 2009 18:31:01 +0000 (18:31 +0000)
committerTony Mack <tmack@cs.princeton.edu>
Tue, 31 Mar 2009 18:31:01 +0000 (18:31 +0000)
PLC/PostgreSQL.py

index 22c2b63..0c4a24a 100644 (file)
@@ -221,7 +221,7 @@ class PostgreSQL:
         cursor = self.execute(query, params)
         rows = cursor.fetchall()
         cursor.close()
-
+        self.close()
         if hashref or key_field is not None:
             # Return each row as a dictionary keyed on field name
             # (like DBI selectrow_hashref()).