85 |
|
|
86 |
def connect(self , connectData={}): |
def connect(self , connectData={}): |
87 |
|
|
88 |
|
print "Postgresql database driver initializing" |
89 |
|
|
90 |
if not hasattr(self,'_DatabaseError'): |
if not hasattr(self,'_DatabaseError'): |
91 |
self._DatabaseError = self._pg_driver.DatabaseError |
self._DatabaseError = self._pg_driver.DatabaseError |
92 |
|
|
129 |
if self._pg_encoding not in ("",'DEFAULT'): |
if self._pg_encoding not in ("",'DEFAULT'): |
130 |
GDebug.printMesg(1,'Setting postgresql client_encoding to %s (%s)' % (self._pg_encoding, |
GDebug.printMesg(1,'Setting postgresql client_encoding to %s (%s)' % (self._pg_encoding, |
131 |
self._encoding)) |
self._encoding)) |
132 |
cursor = self._dataConnection.cursor() |
cursor = self.native.cursor() |
133 |
cursor.execute("SET CLIENT_ENCODING TO '%s'" % self._pg_encoding) |
cursor.execute("SET CLIENT_ENCODING TO '%s'" % self._pg_encoding) |
134 |
cursor.close() |
cursor.close() |
135 |
|
|