Changeset 915 for pykota/trunk/pykota/storages/postgresql.py
- Timestamp:
- 04/15/03 13:30:57 (21 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/pykota/storages/postgresql.py
r873 r915 21 21 # 22 22 # $Log$ 23 # Revision 1.7 2003/04/15 11:30:57 jalet 24 # More work done on money print charging. 25 # Minor bugs corrected. 26 # All tools now access to the storage as priviledged users, repykota excepted. 27 # 23 28 # Revision 1.6 2003/03/29 13:45:27 jalet 24 29 # GPL paragraphs were incorrectly (from memory) copied into the sources. … … 82 87 def doQuery(self, query) : 83 88 """Does a query.""" 89 if type(query) in (type([]), type(())) : 90 query = ";".join(query) 91 query = query.strip() 92 if not query.endswith(';') : 93 query += ';' 94 self.database.query("BEGIN;") 84 95 try : 85 re turnself.database.query(query)96 result = self.database.query(query) 86 97 except pg.error, msg : 98 self.database.query("ROLLBACK;") 87 99 raise PyKotaStorageError, msg 100 else : 101 self.database.query("COMMIT;") 102 return result 88 103 89 104 def doQuote(self, field) :