discussion (including making def_arg allow reserved words), add missed
opt_definition for UNIQUE case. Put the reloptions support code in a less
random place (I chose to make a new file access/common/reloptions.c).
Eliminate header inclusion creep. Make the index options functions safely
user-callable (seems like client apps might like to be able to test validity
of options before trying to make an index). Reduce overhead for normal case
with no options by allowing rd_options to be NULL. Fix some unmaintainably
klugy code, including getting rid of Natts_pg_class_fixed at long last.
Some stylistic cleanup too, and pay attention to keeping comments in sync
with code.
Documentation still needs work, though I did fix the omissions in
catalogs.sgml and indexam.sgml.
< o Add ALTER TABLE tab ADD/DROP INHERITS parent
<
< This allows tables to be added/removed from an inheritance
< hierarchy. This is particularly useful for table partitioning.
< http://archives.postgresql.org/pgsql-hackers/2006-05/msg00988.php
<
> o -Add ALTER TABLE tab INHERIT / NO INHERIT parent
Open items:
There were a few tangentially related issues that have come up that I think
are TODOs. I'm likely to tackle one or two of these next so I'm interested in
hearing feedback on them as well.
. Constraints currently do not know anything about inheritance. Tom suggested
adding a coninhcount and conislocal like attributes have to track their
inheritance status.
. Foreign key constraints currently do not get copied to new children (and
therefore my code doesn't verify them). I don't think it would be hard to
add them and treat them like CHECK constraints.
. No constraints at all are copied to tables defined with LIKE. That makes it
hard to use LIKE to define new partitions. The standard defines LIKE and
specifically says it does not copy constraints. But the standard already has
an option called INCLUDING DEFAULTS; we could always define a non-standard
extension LIKE table INCLUDING CONSTRAINTS that gives the user the option to
request a copy including constraints.
. Personally, I think the whole attislocal thing is bunk. The decision about
whether to drop a column from children tables or not is something that
should be up to the user and trying to DWIM based on whether there was ever
a local definition or the column was acquired purely through inheritance is
hardly ever going to match up with user expectations.
. And of course there's the whole unique and primary key constraint issue. I
think to get any traction at all on this you have a prerequisite of a real
partitioned table implementation where the system knows what the partition
key is so it can recognize when it's a leading part of an index key.
Greg Stark
be delivered directly to the collector process. The extra process context
swaps required to transfer data through the buffer process seem to outweigh
any value the buffering might have. Per recent discussion and tests.
I modified Bruce's draft patch to use poll() rather than select() where
available (this makes a noticeable difference on my system), and fixed
up the EXEC_BACKEND case.
< o Add support for WITH HOLD cursors
> o Add support for WITH HOLD and SCROLL cursors
>
> PL/pgSQL cursors should support the same syntax as
> backend cursors.
>
< * %Disallow changing DEFAULT expression of a SERIAL column?
<
< This should be done only if the existing SERIAL problems cannot be
< fixed.
<
> * -Disallow changing DEFAULT expression of a SERIAL column
will be expanded to a list of their member fields, rather than creating
a nested rowtype field as formerly. (The old behavior is still available
by omitting '.*'.) This syntax is not allowed by the SQL spec AFAICS,
so changing its behavior doesn't violate the spec. The new behavior is
substantially more useful since it allows, for example, triggers to check
for data changes with 'if row(new.*) is distinct from row(old.*)'. Per
my recent proposal.
< * Reuse index tuples that point to rows that are not visible to anyone?
> * Reuse index tuples that point to heap tuples that are not visible to
> anyone?
< * Allow heap reuse of UPDATEd rows if old and new versions are on the
< same heap page?
> * Allow heap reuse of UPDATEd rows if no indexed columns are changed,
> and old and new versions are on the same heap page?
< This is possible for same-page updates because a single index row
< can point to both old and new values.
> While vacuum handles DELETEs fine, updating of non-indexed columns, like
> counters, are difficult for VACUUM to handle efficiently. This method
> is possible for same-page updates because a single index row can be
> used to point to both old and new values.
>
> * Allow heap reuse of UPDATEd rows if old and new versions are on the
> same heap page?
>
> This is possible for same-page updates because a single index row
> can point to both old and new values.
> http://archives.postgresql.org/pgsql-hackers/2006-06/msg01305.php
current commands; instead, store current-status information in shared
memory. This substantially reduces the overhead of stats_command_string
and also ensures that pg_stat_activity is fully up to date at all times.
Per my recent proposal.