source: trunk/docs/changelog.txt @ 638

Last change on this file since 638 was 638, checked in by cito, 4 years ago

Update the documentation

  • Property svn:keywords set to Author Date Id Revision
File size: 14.1 KB
Line 
1ChangeLog
2=========
3
4Version 4.2
5-----------
6- Set a better default for the user option "escaping-funcs".
7- Greatly improve unit testing.
8- Force build to compile with no errors.
9- Fix decimal point handling.
10- Add option to return boolean values as bool objects.
11- Add option to return money values as string.
12- Fix notification handler (Thanks Patrick TJ McPhee).
13
14Version 4.1.1 (2013-01-08)
15--------------------------
16- Add WhenNotified class and method.  Replaces need for third party pgnotify.
17- Sharpen test for inserting current_timestamp.
18- Add more quote tests.  False and 0 should evaluate to NULL.
19- More tests - Any number other than 0 is True.
20- Do not use positional parameters internally.
21  This restores backward compatibility with version 4.0.
22- Add methods for changing the decimal point.
23
24Version 4.1 (2013-01-01)
25------------------------
26- Dropped support for Python below 2.5 and PostgreSQL below 8.3.
27- Added support for Python up to 2.7 and PostgreSQL up to 9.2.
28- Particularly, support PQescapeLiteral() and PQescapeIdentifier().
29- The query method of the classic API now supports positional parameters.
30  This an effective way to pass arbitrary or unknown data without worrying
31  about SQL injection or syntax errors (contribution by Patrick TJ McPhee).
32- The classic API now supports a method namedresult() in addition to
33  getresult() and dictresult(), which returns the rows of the result
34  as named tuples if these are supported (Python 2.6 or higher).
35- The classic API has got the new methods begin(), commit(), rollback(),
36  savepoint() and release() for handling transactions.
37- Both classic and DBAPI 2 connections can now be used as context
38  managers for encapsulating transactions.
39- The execute() and executemany() methods now return the cursor object,
40  so you can now write statements like "for row in cursor.execute(...)"
41  (as suggested by Adam Frederick).
42- Binary objects are now automatically escaped and unescaped.
43- Bug in money quoting fixed.  Amounts of $0.00 handled correctly.
44- Proper handling of date and time objects as input.
45- Proper handling of floats with 'nan' or 'inf' values as input.
46- Fixed the set_decimal() function.
47- All DatabaseError instances now have a sqlstate attribute.
48- The getnotify() method can now also return payload strings (#15).
49- Better support for notice processing with the new methods
50  set_notice_receiver() and get_notice_receiver()
51  (as suggested by Michael Filonenko, see #37).
52- Open transactions are rolled back when pgdb connections are closed
53  (as suggested by Peter Harris, see #46).
54- Connections and cursors can now be used with the "with" statement
55  (as suggested by Peter Harris, see #46).
56- New method use_regtypes() that can be called to let getattnames()
57  return regular type names instead of the simplified classic types (#44).
58
59
60Version 4.0 (2009-01-01)
61------------------------
62- Dropped support for Python below 2.3 and PostgreSQL below 7.4.
63- Improved performance of fetchall() for large result sets
64  by speeding up the type casts (as suggested by Peter Schuller).
65- Exposed exceptions as attributes of the connection object.
66- Exposed connection as attribute of the cursor object.
67- Cursors now support the iteration protocol.
68- Added new method to get parameter settings.
69- Added customizable row_factory as suggested by Simon Pamies.
70- Separated between mandatory and additional type objects.
71- Added keyword args to insert, update and delete methods.
72- Added exception handling for direct copy.
73- Start transactions only when necessary, not after every commit().
74- Release the GIL while making a connection
75  (as suggested by Peter Schuller).
76- If available, use decimal.Decimal for numeric types.
77- Allow DB wrapper to be used with DB-API 2 connections
78  (as suggested by Chris Hilton).
79- Made private attributes of DB wrapper accessible.
80- Dropped dependence on mx.DateTime module.
81- Support for PQescapeStringConn() and PQescapeByteaConn();
82  these are now also used by the internal _quote() functions.
83- Added 'int8' to INTEGER types. New SMALLINT type.
84- Added a way to find the number of rows affected by a query()
85  with the classic pg module by returning it as a string.
86  For single inserts, query() still returns the oid as an integer.
87  The pgdb module already provides the "rowcount" cursor attribute
88  for the same purpose.
89- Improved getnotify() by calling PQconsumeInput() instead of
90  submitting an empty command.
91- Removed compatibility code for old OID munging style.
92- The insert() and update() methods now use the "returning" clause
93  if possible to get all changed values, and they also check in advance
94  whether a subsequent select is possible, so that ongoing transactions
95  won't break if there is no select privilege.
96- Added "protocol_version" and "server_version" attributes.
97- Revived the "user" attribute.
98- The pg module now works correctly with composite primary keys;
99  these are represented as frozensets.
100- Removed the undocumented and actually unnecessary "view" parameter
101  from the get() method.
102- get() raises a nicer ProgrammingError instead of a KeyError
103  if no primary key was found.
104- delete() now also works based on the primary key if no oid available
105  and returns whether the row existed or not.
106
107
108Version 3.8.1 (2006-06-05)
109--------------------------
110- Use string methods instead of deprecated string functions.
111- Only use SQL-standard way of escaping quotes.
112- Added the functions escape_string() and escape/unescape_bytea()
113  (as suggested by Charlie Dyson and Kavous Bojnourdi a long time ago).
114- Reverted code in clear() method that set date to current.
115- Added code for backwards compatibility in OID munging code.
116- Reorder attnames tests so that "interval" is checked for before "int."
117- If caller supplies key dictionary, make sure that all has a namespace.
118
119Version 3.8 (2006-02-17)
120------------------------
121- Installed new favicon.ico from Matthew Sporleder <mspo@mspo.com>
122- Replaced snprintf by PyOS_snprintf.
123- Removed NO_SNPRINTF switch which is not needed any longer
124- Clean up some variable names and namespace
125- Add get_relations() method to get any type of relation
126- Rewrite get_tables() to use get_relations()
127- Use new method in get_attnames method to get attributes of views as well
128- Add Binary type
129- Number of rows is now -1 after executing no-result statements
130- Fix some number handling
131- Non-simple types do not raise an error any more
132- Improvements to documentation framework
133- Take into account that nowadays not every table must have an oid column
134- Simplification and improvement of the inserttable() function
135- Fix up unit tests
136- The usual assortment of minor fixes and enhancements
137
138Version 3.7 (2005-09-07)
139------------------------
140Improvement of pgdb module:
141
142- Use Python standard `datetime` if `mxDateTime` is not available
143
144Major improvements and clean-up in classic pg module:
145
146- All members of the underlying connection directly available in `DB`
147- Fixes to quoting function
148- Add checks for valid database connection to methods
149- Improved namespace support, handle `search_path` correctly
150- Removed old dust and unnessesary imports, added docstrings
151- Internal sql statements as one-liners, smoothed out ugly code
152
153Version 3.6.2 (2005-02-23)
154--------------------------
155- Further fixes to namespace handling
156
157Version 3.6.1 (2005-01-11)
158--------------------------
159- Fixes to namespace handling
160
161Version 3.6 (2004-12-17)
162------------------------
163- Better DB-API 2.0 compliance
164- Exception hierarchy moved into C module and made available to both APIs
165- Fix error in update method that caused false exceptions
166- Moved to standard exception hierarchy in classic API
167- Added new method to get transaction state
168- Use proper Python constants where appropriate
169- Use Python versions of strtol, etc. Allows Win32 build.
170- Bug fixes and cleanups
171
172Version 3.5 (2004-08-29)
173------------------------
174Fixes and enhancements:
175
176- Add interval to list of data types
177- fix up method wrapping especially close()
178- retry pkeys once if table missing in case it was just added
179- wrap query method separately to handle debug better
180- use isinstance instead of type
181- fix free/PQfreemem issue - finally
182- miscellaneous cleanups and formatting
183
184Version 3.4 (2004-06-02)
185------------------------
186Some cleanups and fixes.
187This is the first version where PyGreSQL is moved back out of the
188PostgreSQL tree. A lot of the changes mentioned below were actually
189made while in the PostgreSQL tree since their last release.
190
191- Allow for larger integer returns
192- Return proper strings for true and false
193- Cleanup convenience method creation
194- Enhance debugging method
195- Add reopen method
196- Allow programs to preload field names for speedup
197- Move OID handling so that it returns long instead of int
198- Miscellaneous cleanups and formatting
199
200Version 3.3 (2001-12-03)
201------------------------
202A few cleanups.  Mostly there was some confusion about the latest version
203and so I am bumping the number to keep it straight.
204
205- Added NUMERICOID to list of returned types. This fixes a bug when
206  returning aggregates in the latest version of PostgreSQL.
207
208Version 3.2 (2001-06-20)
209------------------------
210Note that there are very few changes to PyGreSQL between 3.1 and 3.2.
211The main reason for the release is the move into the PostgreSQL
212development tree.  Even the WIN32 changes are pretty minor.
213
214- Add Win32 support (gerhard@bigfoot.de)
215- Fix some DB-API quoting problems (niall.smart@ebeon.com)
216- Moved development into PostgreSQL development tree.
217
218Version 3.1 (2000-11-06)
219------------------------
220- Fix some quoting functions.  In particular handle NULLs better.
221- Use a method to add primary key information rather than direct
222  manipulation of the class structures
223- Break decimal out in `_quote` (in pg.py) and treat it as float
224- Treat timestamp like date for quoting purposes
225- Remove a redundant SELECT from the `get` method speeding it,
226  and `insert` (since it calls `get`) up a little.
227- Add test for BOOL type in typecast method to `pgdbTypeCache` class
228  (tv@beamnet.de)
229- Fix pgdb.py to send port as integer to lower level function
230  (dildog@l0pht.com)
231- Change pg.py to speed up some operations
232- Allow updates on tables with no primary keys
233
234Version 3.0 (2000-05-30)
235------------------------
236- Remove strlen() call from pglarge_write() and get size from object
237  (Richard@Bouska.cz)
238- Add a little more error checking to the quote function in the wrapper
239- Add extra checking in `_quote` function
240- Wrap query in pg.py for debugging
241- Add DB-API 2.0 support to pgmodule.c (andre@via.ecp.fr)
242- Add DB-API 2.0 wrapper pgdb.py (andre@via.ecp.fr)
243- Correct keyword clash (temp) in tutorial
244- Clean up layout of tutorial
245- Return NULL values as None (rlawrence@lastfoot.com)
246  (WARNING: This will cause backwards compatibility issues)
247- Change None to NULL in insert and update
248- Change hash-bang lines to use /usr/bin/env
249- Clearing date should be blank (NULL) not TODAY
250- Quote backslashes in strings in `_quote` (brian@CSUA.Berkeley.EDU)
251- Expanded and clarified build instructions (tbryan@starship.python.net)
252- Make code thread safe (Jerome.Alet@unice.fr)
253- Add README.distutils (mwa@gate.net & jeremy@cnri.reston.va.us)
254- Many fixes and increased DB-API compliance by chifungfan@yahoo.com,
255  tony@printra.net, jeremy@alum.mit.edu and others to get the final
256  version ready to release.
257
258Version 2.4 (1999-06-15)
259------------------------
260- Insert returns None if the user doesn't have select permissions
261  on the table.  It can (and does) happen that one has insert but
262  not select permissions on a table.
263- Added ntuples() method to query object (brit@druid.net)
264- Corrected a bug related to getresult() and the money type
265- Corrected a bug related to negative money amounts
266- Allow update based on primary key if munged oid not available and
267  table has a primary key
268- Add many __doc__ strings (andre@via.ecp.fr)
269- Get method works with views if key specified
270
271Version 2.3 (1999-04-17)
272------------------------
273- connect.host returns "localhost" when connected to Unix socket
274  (torppa@tuhnu.cutery.fi)
275- Use `PyArg_ParseTupleAndKeywords` in connect() (torppa@tuhnu.cutery.fi)
276- fixes and cleanups (torppa@tuhnu.cutery.fi)
277- Fixed memory leak in dictresult() (terekhov@emc.com)
278- Deprecated pgext.py - functionality now in pg.py
279- More cleanups to the tutorial
280- Added fileno() method - terekhov@emc.com (Mikhail Terekhov)
281- added money type to quoting function
282- Compiles cleanly with more warnings turned on
283- Returns PostgreSQL error message on error
284- Init accepts keywords (Jarkko Torppa)
285- Convenience functions can be overridden (Jarkko Torppa)
286- added close() method
287
288Version 2.2 (1998-12-21)
289------------------------
290- Added user and password support thanks to Ng Pheng Siong (ngps@post1.com)
291- Insert queries return the inserted oid
292- Add new `pg` wrapper (C module renamed to _pg)
293- Wrapped database connection in a class
294- Cleaned up some of the tutorial.  (More work needed.)
295- Added `version` and `__version__`.
296  Thanks to thilo@eevolute.com for the suggestion.
297
298Version 2.1 (1998-03-07)
299------------------------
300- return fields as proper Python objects for field type
301- Cleaned up pgext.py
302- Added dictresult method
303
304Version 2.0  (1997-12-23)
305-------------------------
306- Updated code for PostgreSQL 6.2.1 and Python 1.5
307- Reformatted code and converted to use full ANSI style prototypes
308- Changed name to PyGreSQL (from PyGres95)
309- Changed order of arguments to connect function
310- Created new type `pgqueryobject` and moved certain methods to it
311- Added a print function for pgqueryobject
312- Various code changes - mostly stylistic
313
314Version 1.0b (1995-11-04)
315-------------------------
316- Keyword support for connect function moved from library file to C code
317  and taken away from library
318- Rewrote documentation
319- Bug fix in connect function
320- Enhancements in large objects interface methods
321
322Version 1.0a (1995-10-30)
323-------------------------
324A limited release.
325
326- Module adapted to standard Python syntax
327- Keyword support for connect function in library file
328- Rewrote default parameters interface (internal use of strings)
329- Fixed minor bugs in module interface
330- Redefinition of error messages
331
332Version 0.9b (1995-10-10)
333-------------------------
334The first public release.
335
336- Large objects implementation
337- Many bug fixes, enhancements, ...
338
339Version 0.1a (1995-10-07)
340-------------------------
341- Basic libpq functions (SQL access)
Note: See TracBrowser for help on using the repository browser.