]> granicus.if.org Git - postgresql/log
postgresql
25 years agoUpdate from Andreas Zeugswetter <andreas.zeugswetter@telecom.at>
Thomas G. Lockhart [Tue, 14 Sep 1999 15:34:49 +0000 (15:34 +0000)]
Update from Andreas Zeugswetter <andreas.zeugswetter@telecom.at>
 for v6.5.2 info.

25 years agoAllow ISOLATION and LEVEL as column names. These are SQL92 reserved words
Thomas G. Lockhart [Tue, 14 Sep 1999 06:06:31 +0000 (06:06 +0000)]
Allow ISOLATION and LEVEL as column names. These are SQL92 reserved words
 which do not need to be so for our parser. Apparently omitted earlier.

25 years agoPatches for 6.5.2
Peter Mount [Tue, 14 Sep 1999 05:50:44 +0000 (05:50 +0000)]
Patches for 6.5.2

25 years agoUpdate TODO list.
Bruce Momjian [Tue, 14 Sep 1999 02:19:38 +0000 (02:19 +0000)]
Update TODO list.

25 years agoAllow CASE statement to contain *only* untyped result clauses or nulls.
Thomas G. Lockhart [Mon, 13 Sep 1999 04:14:56 +0000 (04:14 +0000)]
Allow CASE statement to contain *only* untyped result clauses or nulls.
 Almost worked before, but forgot one place to check.
 Reported by Tatsuo Ishii.
Still does not do the right thing if inserting into a non-string target
 column. Should look for a type coersion later, but doesn't.

25 years agoPatch to cure O(N^2) behavior in libpq when reading a long
Tom Lane [Mon, 13 Sep 1999 03:00:19 +0000 (03:00 +0000)]
Patch to cure O(N^2) behavior in libpq when reading a long
message under a kernel that only returns one packet per recv() call.  This
didn't use to matter much, but it starts to get annoying with multi-megabyte
EXPLAIN VERBOSE responses...

25 years agoAdd solaris faq.
Bruce Momjian [Mon, 13 Sep 1999 00:21:18 +0000 (00:21 +0000)]
Add solaris faq.

25 years agoFirst cut at doing something reasonable with OR-of-ANDs WHERE
Tom Lane [Mon, 13 Sep 1999 00:17:25 +0000 (00:17 +0000)]
First cut at doing something reasonable with OR-of-ANDs WHERE
conditions.  There are some pretty bogus heuristics in prepqual.c that
try to decide whether to output CNF or DNF format; they need to be replaced,
likely.  Right now the code is probably too willing to choose DNF form,
which might hurt performance in some cases that used to work OK.
But at least we have a foundation to build on.

25 years agoMake sure both SRCH_INC and SRCH_LIB are checked for existances and added to
Marc G. Fournier [Sun, 12 Sep 1999 22:49:47 +0000 (22:49 +0000)]
Make sure both SRCH_INC and SRCH_LIB are checked for existances and added to
the CPPFLAGS/LDFLAGS variables...

25 years agocygwin doesn't have an endian.h, but defines BYTE_ORDER in sys/param.h
Marc G. Fournier [Sun, 12 Sep 1999 22:27:47 +0000 (22:27 +0000)]
cygwin doesn't have an endian.h, but defines BYTE_ORDER in sys/param.h

25 years agoFurther improvements in cnfify: reduce amount of self-recursion
Tom Lane [Sun, 12 Sep 1999 18:08:17 +0000 (18:08 +0000)]
Further improvements in cnfify: reduce amount of self-recursion
in or_normalize, remove detection of duplicate subexpressions (since it's
highly unlikely to be worth the amount of time it takes), and introduce
a dnfify() entry point so that unintelligible backwards logic in UNION
processing can be eliminated.  This is just an intermediate step ---
next thing is to look at not forcing the qual into CNF form when it would
be better off in DNF form.

25 years agoEliminate query length limitation imposed by pg_client_to_server
Tom Lane [Sat, 11 Sep 1999 22:28:11 +0000 (22:28 +0000)]
Eliminate query length limitation imposed by pg_client_to_server
and pg_server_to_client.  Eliminate copy.c's restriction on the length
of a single attribute.

25 years agoEliminate token length assumption in scanstr().
Tom Lane [Sat, 11 Sep 1999 22:26:47 +0000 (22:26 +0000)]
Eliminate token length assumption in scanstr().

25 years agoUpdate protocol doc to emphasize that backend can return
Tom Lane [Sat, 11 Sep 1999 22:02:51 +0000 (22:02 +0000)]
Update protocol doc to emphasize that backend can return
arbitrarily long strings, and frontends should cope gracefully.  Goes
along with long query and long error message changes...

25 years agoEliminate elog()'s hardwired limit on length of an error message.
Tom Lane [Sat, 11 Sep 1999 19:06:42 +0000 (19:06 +0000)]
Eliminate elog()'s hardwired limit on length of an error message.
This change seems necessary in conjunction with long queries, and it
cleans up some bogosity in connection with long EXPLAIN texts anyway.
Note that current libpq will accept any length error message (at least
until it runs out of memory); prior versions have a limit of 8K, but
will cleanly discard excess error text, so there shouldn't be any
big compatibility problems with old clients.

25 years agoAdd information on ssh tunnelling from Gene Selkov.
Thomas G. Lockhart [Fri, 10 Sep 1999 14:20:24 +0000 (14:20 +0000)]
Add information on ssh tunnelling from Gene Selkov.

25 years agoMake pgindent gnu test better.
Bruce Momjian [Thu, 9 Sep 1999 19:39:06 +0000 (19:39 +0000)]
Make pgindent gnu test better.

25 years agoRepair incorrect cleanup of heap memory allocation during
Tom Lane [Thu, 9 Sep 1999 16:25:35 +0000 (16:25 +0000)]
Repair incorrect cleanup of heap memory allocation during
transaction abort --- before it only worked if there was exactly one level
of allocation context stacked in the blank portal.  Now it does the right
thing for any depth, including zero...

25 years agoMinor improvement in SI overflow logic: try to delete
Tom Lane [Thu, 9 Sep 1999 14:56:06 +0000 (14:56 +0000)]
Minor improvement in SI overflow logic: try to delete
expired messages before concluding that we really have buffer overflow.

25 years agoGet rid of elog(DEBUG) in snprintf emulation ... it's just
Tom Lane [Thu, 9 Sep 1999 03:13:22 +0000 (03:13 +0000)]
Get rid of elog(DEBUG) in snprintf emulation ... it's just
cluttering the log file...

25 years agoRepair error noticed by Roberto Cornacchia: selectivity code
Tom Lane [Thu, 9 Sep 1999 02:36:04 +0000 (02:36 +0000)]
Repair error noticed by Roberto Cornacchia: selectivity code
was rejecting negative attnums as bogus, which of course they are not.
Add code to get_attdisbursion to produce a useful value for OID attribute,
since VACUUM does not store stats for system attributes.
Also, repair bug that's been in eqjoinsel for a long time: it was taking
the max of the two columns' disbursions, whereas it should use the min.

25 years agoStreamConnection() mustn't call elog().
Tom Lane [Wed, 8 Sep 1999 22:57:12 +0000 (22:57 +0000)]
StreamConnection() mustn't call elog().

25 years agoCope with versions of vsnprintf() written by people who
Tom Lane [Wed, 8 Sep 1999 16:31:38 +0000 (16:31 +0000)]
Cope with versions of vsnprintf() written by people who
don't read man pages...

25 years agoRepair logic error in LIKE: should not return LIKE_ABORT
Tom Lane [Tue, 7 Sep 1999 19:09:46 +0000 (19:09 +0000)]
Repair logic error in LIKE: should not return LIKE_ABORT
when reach end of pattern before end of text.  Improve code comments.

25 years agoIrix linking fix from Yu Cao <yucao@falcon.kla-tencor.com>
Tom Lane [Tue, 7 Sep 1999 18:10:49 +0000 (18:10 +0000)]
Irix linking fix from Yu Cao <yucao@falcon.kla-tencor.com>

25 years agoUpdate TODO list.
Bruce Momjian [Tue, 7 Sep 1999 03:58:13 +0000 (03:58 +0000)]
Update TODO list.

25 years agoPerformance improvements in cnfify(): get rid of exponential
Tom Lane [Tue, 7 Sep 1999 03:47:06 +0000 (03:47 +0000)]
Performance improvements in cnfify(): get rid of exponential
space consumption in pull_args, and avoid doing the full CNF transform on
operands of operator clauses, where it's really not particularly helpful.
This answers the TODO item about large numbers of OR clauses, at least
partially.  I was able to do a ten-thousand-OR-clause query with about
20Mb memory consumption ... it took an obscenely long time, but it worked...

25 years agoMike Ansley's fixes for long queries. This change just
Tom Lane [Tue, 7 Sep 1999 00:13:27 +0000 (00:13 +0000)]
Mike Ansley's fixes for long queries.  This change just
corrects flex myinput() routine so that it doesn't assume there is only
one bufferload of data.  We still have the issue of getting rid of
YY_USES_REJECT so that the scanner can cope with tokens larger than its
initial buffer size.

25 years agoAdditional long-query fixes from Mike Ansley and yours truly.
Tom Lane [Mon, 6 Sep 1999 23:30:53 +0000 (23:30 +0000)]
Additional long-query fixes from Mike Ansley and yours truly.
psql.c seems clean of query length restrictions now.

25 years agoMark bpchareq not hashjoinable, since it strips trailing blanks
Tom Lane [Mon, 6 Sep 1999 21:16:20 +0000 (21:16 +0000)]
Mark bpchareq not hashjoinable, since it strips trailing blanks
before comparison; if fields being joined are different widths then hashing
will yield wrong answer.  Also, remove hashjoinable mark from all uses of
array_eq, because array structures may have padding bytes between elements
and the pad bytes are of uncertain content.  This could be revisited if
array code is cleaned up.
Modify opr_sanity regress test to complain if array_eq operator is marked
hashjoinable.

25 years agoI finally understood what sinvaladt.c is doing --- and it
Tom Lane [Mon, 6 Sep 1999 19:37:38 +0000 (19:37 +0000)]
I finally understood what sinvaladt.c is doing --- and it
offended my aesthestic sensibility that there was so much unreadable code
doing so little.  Rewritten code is about half the size, faster, and
(I hope) much more intelligible.

25 years agoFix relcache.c so that local relations (those created during
Tom Lane [Mon, 6 Sep 1999 19:33:16 +0000 (19:33 +0000)]
Fix relcache.c so that local relations (those created during
current transaction) are not flushed by shared-cache-inval reset message.
SI reset actually works now, for probably the first time in a long time.
I was able to run initdb and regression tests with a 16-element SI message
array, with a lot of NOTICE: cache state reset messages but no crashes.

25 years agoRelationCacheInvalidate thought there were 7 nailed-in-cache
Tom Lane [Mon, 6 Sep 1999 18:13:02 +0000 (18:13 +0000)]
RelationCacheInvalidate thought there were 7 nailed-in-cache
system tables, but actually there are only 6 --- see RelationInitialize.
Kinda makes you wonder how long ago this code was last executed...

25 years agotest
Bruce Momjian [Mon, 6 Sep 1999 15:15:07 +0000 (15:15 +0000)]
test

25 years agoPer Tatsuo's recommendation, change mdopen so that it won't
Tom Lane [Sun, 5 Sep 1999 23:24:53 +0000 (23:24 +0000)]
Per Tatsuo's recommendation, change mdopen so that it won't
automatically create the file, except during bootstrap mode where that
seems to be necessary.

25 years agoDisallow DROP TABLE/DROP INDEX inside a transaction block.
Tom Lane [Sun, 5 Sep 1999 17:43:47 +0000 (17:43 +0000)]
Disallow DROP TABLE/DROP INDEX inside a transaction block.
We can't support these properly, since once the relation's physical files
are unlinked, there's no way to roll back the transaction.  I suppose
we could postpone the unlink till transaction commit, but then what of
BEGIN; DROP TABLE foo; CREATE TABLE foo; ?
The code does allow dropping a table/index created in the current
transaction block, however, since the post-abort state would be that
the table doesn't exist anyway.

25 years agoIsTransactionBlock() should return true in TBLOCK_ABORT state.
Tom Lane [Sun, 5 Sep 1999 17:12:34 +0000 (17:12 +0000)]
IsTransactionBlock() should return true in TBLOCK_ABORT state.

25 years agoremove elogs used for debugging.
Bruce Momjian [Sat, 4 Sep 1999 22:03:09 +0000 (22:03 +0000)]
remove elogs used for debugging.

25 years agoIntercept temp table lookups further up to map temp names.
Bruce Momjian [Sat, 4 Sep 1999 22:00:30 +0000 (22:00 +0000)]
Intercept temp table lookups further up to map temp names.

25 years agoIn RelationNameGetRelation(), replace temp table name by
Tom Lane [Sat, 4 Sep 1999 21:47:23 +0000 (21:47 +0000)]
In RelationNameGetRelation(), replace temp table name by
real name before doing lookup.  We only want to index temp tables by their
real names in the relcache, to ensure there's not more than one relcache
entry for them.

25 years agoAvoid transaction overhead when there are no temp tables
Tom Lane [Sat, 4 Sep 1999 21:45:48 +0000 (21:45 +0000)]
Avoid transaction overhead when there are no temp tables
to be deleted.

25 years agoRemove no-longer-needed code to update temprel's copy of
Tom Lane [Sat, 4 Sep 1999 21:19:33 +0000 (21:19 +0000)]
Remove no-longer-needed code to update temprel's copy of
pg_class tuple during ALTER TABLE ADD COLUMN.

25 years agoInvalidate temp entries for aborted transactions.
Bruce Momjian [Sat, 4 Sep 1999 19:55:50 +0000 (19:55 +0000)]
Invalidate temp entries for aborted transactions.

25 years agoModify RelationFlushRelation so that if the relcache entry
Tom Lane [Sat, 4 Sep 1999 18:42:15 +0000 (18:42 +0000)]
Modify RelationFlushRelation so that if the relcache entry
has positive refcount, it is rebuilt from pg_class data.  This ensures
that relcache entries will track changes made by other backends.  Formerly,
a shared inval report would just be ignored if it happened to arrive while
the relcache entry was in use.  Also, fix relcache to reset ref counts
to zero during transaction abort.  Finally, change LockRelation() so that
it checks for shared inval reports after obtaining the lock.  In this way,
once any kind of lock has been obtained on a rel, we can trust the relcache
entry to be up-to-date.

25 years agoModify sinval so that InvalidateSharedInvalid() does not hold
Tom Lane [Sat, 4 Sep 1999 18:36:45 +0000 (18:36 +0000)]
Modify sinval so that InvalidateSharedInvalid() does not hold
the SInval spinlock while it is calling the passed invalFunction or
resetFunction.  This is necessary to avoid deadlock with lmgr change;
InvalidateSharedInvalid can be called recursively now.  It should be
a good performance improvement anyway --- holding a spinlock for more
than a very short interval is a no-no.

25 years agoFix for perl5 on BSD/OS breaks most other platforms, so back it out.
Thomas G. Lockhart [Fri, 3 Sep 1999 13:46:33 +0000 (13:46 +0000)]
Fix for perl5 on BSD/OS breaks most other platforms, so back it out.
istm that this would be a job for configure.
Most modern OSes actually use perl5 by default ;)

25 years agodriver v06-40-0007
Byron Nikolaidis [Fri, 3 Sep 1999 05:29:00 +0000 (05:29 +0000)]
driver v06-40-0007

25 years agodriver v06-40-0007
Byron Nikolaidis [Fri, 3 Sep 1999 04:41:45 +0000 (04:41 +0000)]
driver v06-40-0007

25 years agoRule deparser didn't handle unary operators correctly.
Tom Lane [Thu, 2 Sep 1999 03:04:04 +0000 (03:04 +0000)]
Rule deparser didn't handle unary operators correctly.

25 years agoRepair a bunch of problems in md.c. This builds on Hiroshi's
Tom Lane [Thu, 2 Sep 1999 02:57:50 +0000 (02:57 +0000)]
Repair a bunch of problems in md.c.  This builds on Hiroshi's
insight that RelationFlushRelation ought to invoke smgrclose, and that the
way to make that work is to ensure that mdclose doesn't fail if the relation
is already closed (or unlinked, if we are looking at a DROP TABLE).  While
I was testing that, I was able to identify several problems that we had
with multiple-segment relations.  The system is now able to do initdb and
pass the regression tests with a very small segment size (I had it set to
64Kb per segment for testing).  I don't believe that ever worked before.
File descriptor leaks seem to be gone too.
I have partially addressed the concerns we had about mdtruncate(), too.
On a Win32 or NFS filesystem it is not possible to unlink a file that
another backend is holding open, so what md.c now does is to truncate
unwanted files to zero length before trying to unlink them.  The other
backends will be forced to close their open files by relation cache
invalidation --- but I think it would take considerable work to make
that happen before vacuum truncates the relation rather than after.
Leaving zero-length files lying around seems a usable compromise.

25 years agoDocument -x properly for pg_dump.
Bruce Momjian [Wed, 1 Sep 1999 23:05:20 +0000 (23:05 +0000)]
Document -x properly for pg_dump.

25 years agoFix wording on allowed/forbidden keyword usage.
Thomas G. Lockhart [Wed, 1 Sep 1999 02:37:40 +0000 (02:37 +0000)]
Fix wording on allowed/forbidden keyword usage.
 Thanks to Michael Deck <deckm@cleansoft.com> for the tipoff.
Add more examples for language components.

25 years agoCommit the bulk of Mike Ansley's long-query changes in the
Tom Lane [Tue, 31 Aug 1999 04:26:40 +0000 (04:26 +0000)]
Commit the bulk of Mike Ansley's long-query changes in the
backend.  Still much left to do.

25 years agoUpdate frontend libpq to remove limits on query lengths,
Tom Lane [Tue, 31 Aug 1999 01:37:37 +0000 (01:37 +0000)]
Update frontend libpq to remove limits on query lengths,
error/notice message lengths, and number of fields per tuple.  Add
pqexpbuffer.c/.h, a frontend version of backend's stringinfo module.
This is first step in applying Mike Ansley's long-query patches,
even though he didn't do any of these particular changes...

25 years agoMinor improvements to stringinfo package to make it more
Tom Lane [Tue, 31 Aug 1999 01:28:37 +0000 (01:28 +0000)]
Minor improvements to stringinfo package to make it more
robust, since it's about to get used much more heavily.

25 years agoFix quoting problems in mkMakefile.tcldefs.sh.in and
Tom Lane [Sun, 29 Aug 1999 20:09:44 +0000 (20:09 +0000)]
Fix quoting problems in mkMakefile.tcldefs.sh.in and
mkMakefile.tkdefs.sh.in.

25 years agoCorrect broken entries for pg_proc OIDs 1364 (time(abstime))
Tom Lane [Sun, 29 Aug 1999 01:35:11 +0000 (01:35 +0000)]
Correct broken entries for pg_proc OIDs 1364 (time(abstime))
and 1370 (timestamp(datetime)).  This does not force an initdb, exactly,
but you won't see the effects of the bug fix until you do one.
BTW, OID 1358 for timespan(time) is still broken:
select timespan('21:11:26'::time);
ERROR:  No such function 'time_timespan' with the specified attributes
But I couldn't figure out what it ought to be defined as, so I left it be.

25 years agoUpdate rules test expected output to conform to slightly
Tom Lane [Sat, 28 Aug 1999 04:00:41 +0000 (04:00 +0000)]
Update rules test expected output to conform to slightly
more verbose results from ruleutils.c changes.

25 years agoFix several problems in rule deparsing: didn't handle array
Tom Lane [Sat, 28 Aug 1999 03:59:05 +0000 (03:59 +0000)]
Fix several problems in rule deparsing: didn't handle array
references or CASE expressions, didn't parenthesize complex expressions
properly.  Also, always output variable references as fully qualified
names to eliminate ambiguity bug recently reported.  (This could be
smarter, but reliability comes first.)

25 years agoClean up some mistakes in handling of uplevel Vars in planner.
Tom Lane [Thu, 26 Aug 1999 05:09:06 +0000 (05:09 +0000)]
Clean up some mistakes in handling of uplevel Vars in planner.
Most parts of the planner should ignore, or indeed never even see, uplevel
Vars because they will be or have been replaced by Params.  There were a
couple of places that got it wrong though, probably my fault from recent
changes...

25 years agoClean up some bugs in oper_select_candidate(), notably the
Tom Lane [Thu, 26 Aug 1999 04:59:15 +0000 (04:59 +0000)]
Clean up some bugs in oper_select_candidate(), notably the
last loop which would return the *first* surviving-to-that-point candidate
regardless of which one actually passed the test.  This was producing
such curious results as 'oid % 2' getting translated to 'int2(oid) % 2'.

25 years agoRevise implementation of SubLinks so that there is a consistent,
Tom Lane [Wed, 25 Aug 1999 23:21:43 +0000 (23:21 +0000)]
Revise implementation of SubLinks so that there is a consistent,
documented intepretation of the lefthand and oper fields.  Fix a number of
obscure problems while at it --- for example, the old code failed if the parser
decided to insert a type-coercion function just below the operator of a
SubLink.
CAUTION: this will break stored rules that contain subplans.  You may
need to initdb.

25 years agoFix vacuum's memory consumption
Tatsuo Ishii [Wed, 25 Aug 1999 12:20:57 +0000 (12:20 +0000)]
Fix vacuum's memory consumption

25 years agoAdd new vpl_num_allocated_pages member to VPageListData.
Tatsuo Ishii [Wed, 25 Aug 1999 12:18:31 +0000 (12:18 +0000)]
Add new vpl_num_allocated_pages member to VPageListData.
It will keep track the number of pages allocated so that
vacuum could allocate twice of the previous allocation.
This will greatly reduce the total memory consumption of
vacuum.

25 years agoAlter AllocSet routines so that requests larger than
Tom Lane [Tue, 24 Aug 1999 20:11:19 +0000 (20:11 +0000)]
Alter AllocSet routines so that requests larger than
ALLOC_BIGCHUNK_LIMIT are always allocated as separate malloc() blocks,
and are free()d immediately upon pfree().  Also, if such a chunk is enlarged
with repalloc(), translate the operation into a realloc() so as to
minimize memory usage.  Of course, these large chunks still get freed
automatically if the alloc set is reset.
I have set ALLOC_BIGCHUNK_LIMIT at 64K for now, but perhaps another
size would be better?

25 years agocoerce_type() failed to guard against trying to convert a NULL
Tom Lane [Tue, 24 Aug 1999 00:09:56 +0000 (00:09 +0000)]
coerce_type() failed to guard against trying to convert a NULL
constant to a different type.  Not sure that this could happen in ordinary
parser usage, but it can in some new code I'm working on...

25 years agoRemove bogus code in oper_exact --- if it didn't find an exact
Tom Lane [Mon, 23 Aug 1999 23:48:39 +0000 (23:48 +0000)]
Remove bogus code in oper_exact --- if it didn't find an exact
match then it tried for a self-commutative operator with the reversed input
data types.  This is pretty silly; there could never be such an operator,
except maybe in binary-compatible-type scenarios, and we have oper_inexact
for that.  Besides which, the oprsanity regress test would complain about
such an operator.  Remove nonfunctional code and simplify routine calling
convention accordingly.

25 years agoFurther sort-order twiddling in optimizer: be smart about
Tom Lane [Sun, 22 Aug 1999 23:56:45 +0000 (23:56 +0000)]
Further sort-order twiddling in optimizer: be smart about
case where ORDER BY and GROUP BY request the same sort order.

25 years agoUn-break code generated by ECPGRelease production.
Tom Lane [Sun, 22 Aug 1999 20:37:24 +0000 (20:37 +0000)]
Un-break code generated by ECPGRelease production.

25 years agoFurther planner/optimizer cleanups. Move all set_tlist_references
Tom Lane [Sun, 22 Aug 1999 20:15:04 +0000 (20:15 +0000)]
Further planner/optimizer cleanups.  Move all set_tlist_references
and fix_opids processing to a single recursive pass over the plan tree
executed at the very tail end of planning, rather than haphazardly here
and there at different places.  Now that tlist Vars do not get modified
until the very end, it's possible to get rid of the klugy var_equal and
match_varid partial-matching routines, and just use plain equal()
throughout the optimizer.  This is a step towards allowing merge and
hash joins to be done on expressions instead of only Vars ...

25 years agoMajor revision of sort-node handling: push knowledge of query
Tom Lane [Sat, 21 Aug 1999 03:49:17 +0000 (03:49 +0000)]
Major revision of sort-node handling: push knowledge of query
sort order down into planner, instead of handling it only at the very top
level of the planner.  This fixes many things.  An explicit sort is now
avoided if there is a cheaper alternative (typically an indexscan) not
only for ORDER BY, but also for the internal sort of GROUP BY.  It works
even when there is no other reason (such as a WHERE condition) to consider
the indexscan.  It works for indexes on functions.  It works for indexes
on functions, backwards.  It's just so cool...

CAUTION: I have changed the representation of SortClause nodes, therefore
THIS UPDATE BREAKS STORED RULES.  You will need to initdb.

25 years agoCleanups for int8: guard against null inputs in comparison
Tom Lane [Sat, 21 Aug 1999 03:06:58 +0000 (03:06 +0000)]
Cleanups for int8: guard against null inputs in comparison
operators (and some other places), fix rangechecks in int8 to int4
conversion (same problem we recently figured out in pg_atoi).

25 years agoOoops ... I had left some test coding in selfuncs.c that
Tom Lane [Sat, 21 Aug 1999 00:56:18 +0000 (00:56 +0000)]
Ooops ... I had left some test coding in selfuncs.c that
failed on 'field < textconstant' ...

25 years agoUpdate TODO list.
Bruce Momjian [Wed, 18 Aug 1999 15:11:52 +0000 (15:11 +0000)]
Update TODO list.

25 years agoOld multi-byte bug. Forgot to rename #ifdef MB to #ifdef MULTIBYTE
Tatsuo Ishii [Wed, 18 Aug 1999 13:04:45 +0000 (13:04 +0000)]
Old multi-byte bug. Forgot to rename #ifdef MB to #ifdef MULTIBYTE
Now SET NAMES working again...

25 years agoRemove extraneous SeqScan node that make_noname was inserting
Tom Lane [Wed, 18 Aug 1999 04:15:16 +0000 (04:15 +0000)]
Remove extraneous SeqScan node that make_noname was inserting
above a Sort or Materialize node.  As far as I can tell, the only place
that actually needed that was set_tlist_references, which was being lazy
about checking to see if it had a noname node to fix or not...

25 years agoAdd script that runs the regression tests with all valid
Tom Lane [Tue, 17 Aug 1999 21:21:22 +0000 (21:21 +0000)]
Add script that runs the regression tests with all valid
combinations of query-plan-type backend options.  Good for testing
planner/optimizer.  Tedious, though.

25 years agoAdd missing docs semicolon.
Bruce Momjian [Tue, 17 Aug 1999 17:31:11 +0000 (17:31 +0000)]
Add missing docs semicolon.

25 years agoEXPLAIN didn't know about 'Materialize' plan nodes.
Tom Lane [Mon, 16 Aug 1999 23:47:23 +0000 (23:47 +0000)]
EXPLAIN didn't know about 'Materialize' plan nodes.

25 years agoAssign sort keys properly when there are duplicate entries in
Tom Lane [Mon, 16 Aug 1999 23:07:20 +0000 (23:07 +0000)]
Assign sort keys properly when there are duplicate entries in
pathkey list --- corrects misbehavior seen with multiple mergejoin clauses
mentioning same variable.

25 years agoTypo fix
Bruce Momjian [Mon, 16 Aug 1999 20:32:34 +0000 (20:32 +0000)]
Typo fix

25 years ago I've sent 3 mails to pgsql-patches. There are two files, one for doc
Bruce Momjian [Mon, 16 Aug 1999 20:27:19 +0000 (20:27 +0000)]
   I've sent 3 mails to pgsql-patches. There are two files, one for doc
and
for src/data directories, and one minor patch for doc/README.locale.
   Please apply.

Oleg.

25 years agoFix for perl5 on BSD/OS.
Bruce Momjian [Mon, 16 Aug 1999 20:12:12 +0000 (20:12 +0000)]
Fix for perl5 on BSD/OS.

25 years agoChange >& to > and 2>&1.
Bruce Momjian [Mon, 16 Aug 1999 19:59:25 +0000 (19:59 +0000)]
Change >& to > and 2>&1.

25 years agoAllow BSD yacc and bison to compile pl code.
Bruce Momjian [Mon, 16 Aug 1999 19:57:21 +0000 (19:57 +0000)]
Allow BSD yacc and bison to compile pl code.

25 years agoMajor planner/optimizer revision: get rid of PathOrder node type,
Tom Lane [Mon, 16 Aug 1999 02:17:58 +0000 (02:17 +0000)]
Major planner/optimizer revision: get rid of PathOrder node type,
store all ordering information in pathkeys lists (which are now lists of
lists of PathKeyItem nodes, not just lists of lists of vars).  This was
a big win --- the code is smaller and IMHO more understandable than it
was, even though it handles more cases.  I believe the node changes will
not force an initdb for anyone; planner nodes don't show up in stored
rules.

25 years agoSmall updates to #include lists for pending optimizer checkin.
Tom Lane [Mon, 16 Aug 1999 02:10:13 +0000 (02:10 +0000)]
Small updates to #include lists for pending optimizer checkin.

25 years agoMove funcid_get_rettype() to lsyscache.
Tom Lane [Mon, 16 Aug 1999 02:08:59 +0000 (02:08 +0000)]
Move funcid_get_rettype() to lsyscache.

25 years agoAdd get_func_rettype() to general-use lsyscache routines,
Tom Lane [Mon, 16 Aug 1999 02:06:25 +0000 (02:06 +0000)]
Add get_func_rettype() to general-use lsyscache routines,
since it's now needed in both optimizer and parser.

25 years agoFix for Win32 making problem with MB enabled.
Tatsuo Ishii [Mon, 16 Aug 1999 02:04:05 +0000 (02:04 +0000)]
Fix for Win32 making problem with MB enabled.
Patches created by Hiroki Kataoka.

25 years agoRepair the check for redundant UNIQUE and PRIMARY KEY indices.
Thomas G. Lockhart [Sun, 15 Aug 1999 06:46:49 +0000 (06:46 +0000)]
Repair the check for redundant UNIQUE and PRIMARY KEY indices.
Also, improve it so that it checks for multi-column constraints.
Thanks to Mark Dalphin <mdalphin@amgen.com> for reporting the problem.

25 years agoLispUnion fix changes output ordering for inheritance tests.
Tom Lane [Sat, 14 Aug 1999 19:30:21 +0000 (19:30 +0000)]
LispUnion fix changes output ordering for inheritance tests.

25 years agoLispUnion routine didn't generate a proper union: anytime
Tom Lane [Sat, 14 Aug 1999 19:29:35 +0000 (19:29 +0000)]
LispUnion routine didn't generate a proper union: anytime
l2 contained more than one entry, there would be duplicates in the output
list.  Miscellaneous code beautification in other routines, too.

25 years agoUpdate TODO list.
Bruce Momjian [Fri, 13 Aug 1999 16:56:04 +0000 (16:56 +0000)]
Update TODO list.

25 years agoUpdate comments about pathkeys.
Tom Lane [Fri, 13 Aug 1999 01:17:16 +0000 (01:17 +0000)]
Update comments about pathkeys.

25 years agoClean up optimizer's handling of indexscan quals that need to be
Tom Lane [Thu, 12 Aug 1999 04:32:54 +0000 (04:32 +0000)]
Clean up optimizer's handling of indexscan quals that need to be
commuted (ie, the index var appears on the right).  These are now handled
the same way as merge and hash join quals that need to be commuted: the
actual reversing of the clause only happens if we actually choose the path
and generate a plan from it.  Furthermore, the clause is only reversed in
the 'indexqual' field of the plan, not in the 'indxqualorig' field.  This
allows the clause to still be recognized and removed from qpquals of upper
level join plans.  Also, simplify and generalize match_clause_to_indexkey;
now it recognizes binary-compatible indexes for join as well as restriction
clauses.

25 years agoAdd commentary to show that even though ExecInitIndexScan()
Tom Lane [Thu, 12 Aug 1999 00:42:43 +0000 (00:42 +0000)]
Add commentary to show that even though ExecInitIndexScan()
contains much code that looks like it will handle indexquals with the index
key on either side of the operator, in fact indexquals must have the index
key on the left because of limitations of the ScanKey machinery.  Perhaps
someone will be motivated to fix that someday...

25 years agoUpdate TODO list.
Bruce Momjian [Tue, 10 Aug 1999 16:56:54 +0000 (16:56 +0000)]
Update TODO list.

25 years agoMinor cleanups and code beautification; eliminate some
Tom Lane [Tue, 10 Aug 1999 03:00:15 +0000 (03:00 +0000)]
Minor cleanups and code beautification; eliminate some
routines that are now dead code.

25 years agoRevise create_nestloop_node's handling of inner indexscan to
Tom Lane [Tue, 10 Aug 1999 02:58:56 +0000 (02:58 +0000)]
Revise create_nestloop_node's handling of inner indexscan to
work under a wider range of scenarios than it did --- it formerly did not
handle a multi-pass inner scan, nor cases in which the inner scan's
indxqualorig or non-index qual contained outer var references.  I am not
sure that these limitations could be hit in the existing optimizer, but
they need to be fixed for future expansion.