D'Arcy J.M. Cain schrieb:
The insert method hasn't returned the OID for a long time. The
documentation is wrong. Let's fix that and move on. In fact I did fix
that earlier today.
Or did you mean that the OID isn't in the return dictionary? Is that
an issue do you think?
Not sure. It would be nice to have a way to get the OID back. Maybe we
can make the return_change an expression that will be used in the
returning clause, so we have full flexibility (it could then also be
renamed to "returning"). A value of True would be equivalent to "*".
Also, I noticed that the behavior of insert(), update() and delete() is
not as consistent as it could be. For instance, update() can work
without an oid and work with primary keys instead, but delete() needs an
oid. And similar to insert(), update() could also make use of a
return_changes parameter and the returning clause.
Will think about this some more and propose some changes to make things
more consistent and flexible (so that pg can be used with and without
oids). I now think this should be cleaned up before 4.0 since making it
clean and consistent will probably require slight changes in behavior
and method signatures which are better done in a major release.
-- Christoph
_______________________________________________
PyGreSQL mailing list
[email protected]
http://mailman.vex.net/mailman/listinfo/pygresql