Commit Graph

6770 Commits

Author SHA1 Message Date
Tom Lane 5c462baebc transformCreateStmt should put Ident nodes, not ColumnDef nodes, into
keys lists of Constraint nodes.  This eliminates a type pun that would
probably have caused trouble someday, and eliminates circular references
in the parsetree that were causing trouble now.
Also, change parser's uses of strcasecmp() to strcmp().  Since scan.l
has downcased any unquoted identifier, it is never correct to check an
identifier with strcasecmp() in the parser.  For example,
	CREATE TABLE FOO (f1 int, UNIQUE("F1"));
was accepted, which is wrong, and xlateSqlFunc did more than it should:
select datetime();
ERROR:  Function 'timestamp()' does not exist
(good)
select "DateTime"();
ERROR:  Function 'timestamp()' does not exist
(bad)
2000-03-24 23:34:19 +00:00
Tom Lane 8f50f7a291 Improve comment. 2000-03-24 23:26:45 +00:00
Tom Lane 8cbeb5f131 Save a few cycles in simple cases: no need to call cost_sort() when there
is no presorted path to compare with.
2000-03-24 21:40:43 +00:00
Bruce Momjian c07118b3b3 Remove -O2 for aix. 2000-03-24 14:39:07 +00:00
Bruce Momjian be0204133c Move LOCK terms down. 2000-03-24 03:57:06 +00:00
Tom Lane 39cd6e2e91 outfuncs.c was missing a print routine for Material plan nodes, leading
to trouble when trying to EXPLAIN VERBOSE a plan containing one.
2000-03-24 02:58:25 +00:00
Tom Lane eca02fee2c Rename bytea functions to not have upper-case letters in their names.
Clean up grotty coding in them, too.  AFAICS from the CVS logs, these
have been broken since Postgres95, so I'm not going to insist on an
initdb to fix them now...
2000-03-24 02:41:46 +00:00
Tom Lane 0edcee3459 Fold PQsetenv working state into PGconn, rather than trying to maintain
it in a separate object.  There's no value in keeping the state separate,
and it creates dangling-pointer problems.  Also, remove PQsetenv routines
from public API, until and unless they are redesigned to have a safer
interface.  Since they were never part of the documented API before 7.0,
it's unlikely that anyone is calling them.
2000-03-24 01:39:55 +00:00
Tatsuo Ishii 5b1f92eaa7 Update multi-byte support README 2000-03-24 01:37:11 +00:00
Bruce Momjian 853cf66176 Update HISTORY 2000-03-24 01:20:09 +00:00
Tom Lane 7177bbac29 A little further tweaking of the range-query selectivity logic:
to avoid undue sensitivity to roundoff error, believe that a zero
or slightly negative range estimate should represent a small
positive selectivity, rather than falling back on a generic default
estimate.
2000-03-23 23:35:47 +00:00
Bruce Momjian 6d79d6027c >> 5. empty define that results in an empty but terminated line ( ; )
easy (maybe dumb) fix for 5 in attachment define.patch

greetings, Andreas
2000-03-23 23:16:49 +00:00
Bruce Momjian f8645018bc Back out // compiler flag. 2000-03-23 22:25:36 +00:00
Bruce Momjian 4ddc50dffa Hmm, absolute pathnames for the copy makes sense. I'll whip up that
patch in a second. Should be sufficent to just make sure the first
character is a '/', right?

Ross J. Reedstrom
2000-03-23 21:38:58 +00:00
Bruce Momjian b2d867fb08 Some points for portability improvements:
1. C++ style comments in C source for ecpg ( // comment )
2. compiler finds wrong include file extern.h in ecpg/lib/descriptor.c
from
include path instead of workdir (rename it ?)
3. fe-connect getsockopt takes a socklen_t as fifth arg not int (use
SOCKET_SIZE_TYPE instead)
4. char vs unsigned char in psql calls to libpq
5. empty define that results in an empty but terminated line ( ; )

Now for all but point 3 I can supply changes to the
compiler flags, to make the compiler less pedantic.
Or is someone interested in the complications ?

in the meantime can someone apply the attached patch ?

Andreas
2000-03-23 17:27:36 +00:00
Bruce Momjian 90cb4c89df Update history/sgml. 2000-03-23 15:09:56 +00:00
Bruce Momjian 2f839c58e2 Please apply the attached patch to interfaces/libpq/libpq-fe.h. This would
allow to write applications which do not have a link to postgres_ext.h in
their source directory.

Andreas Kardos
2000-03-23 15:00:11 +00:00
Michael Meskes ac3884e2a9 *** empty log message *** 2000-03-23 07:53:48 +00:00
Tom Lane 3097788f66 subselect regress test was kind of silly; it claimed to test correlation
cases but actually did no such thing.  Make it test some more cases than
before (including things that didn't work in 6.5).
2000-03-23 07:42:13 +00:00
Tom Lane 5c63975504 Float-to-int conversion functions should return NULL when given NULL
input, not throw a gratuitous elog().
2000-03-23 07:40:00 +00:00
Tom Lane 37ab088770 Remove no-longer-necessary restriction against uplevel correlation vars
outside WHERE clause.  Fix a couple of places that didn't handle uplevel
refs cleanly.
2000-03-23 07:38:30 +00:00
Tom Lane dadb14fa60 Hack parse_coerce so it won't try to constant-fold the dummy Const
nodes introduced by make_subplan().  It'd be better if we used a
different node type for subplan result placeholders, but for now...
2000-03-23 07:36:03 +00:00
Tom Lane 9da6d2c0e7 ExecSubPlan needs to be able to cope with RelabelType nodes atop the
Const placeholder nodes for subplan result values.
2000-03-23 07:32:58 +00:00
Bruce Momjian b212e7ad7b Update TODO list. 2000-03-23 06:35:58 +00:00
Bruce Momjian b508136d81 Update HISTORY file for 7.0. 2000-03-23 06:30:58 +00:00
Tatsuo Ishii 5ca8eb9216 Prepare for 7.0 release 2000-03-23 02:04:07 +00:00
Tom Lane 1afaa2557a If we cannot get a real estimate for the selectivity of a range query,
use a default value that's fairly small.  We were generating a result
of about 0.1, but I think 0.01 is probably better --- want to encourage
use of an indexscan in this situation.
2000-03-23 00:58:36 +00:00
Tom Lane cad764f349 Improve selectivity estimation involving string constants: pay attention
to more than one character, and try to do the right thing in non-ASCII
locales.
2000-03-23 00:55:42 +00:00
Tom Lane 1d5e7a6f46 Repair logic flaw in cost estimator: cost_nestloop() was estimating CPU
costs using the inner path's parent->rows count as the number of tuples
processed per inner scan iteration.  This is wrong when we are using an
inner indexscan with indexquals based on join clauses, because the rows
count in a Relation node reflects the selectivity of the restriction
clauses for that rel only.  Upshot was that if join clause was very
selective, we'd drastically overestimate the true cost of the join.
Fix is to calculate correct output-rows estimate for an inner indexscan
when the IndexPath node is created and save it in the path node.
Change of path node doesn't require initdb, since path nodes don't
appear in saved rules.
2000-03-22 22:08:35 +00:00
Bruce Momjian d825e55c13 Update pg_dumpall again. 2000-03-22 05:25:06 +00:00
Bruce Momjian 233a52eaff Fix pg_dumpall for new psql output. 2000-03-22 05:10:22 +00:00
Tom Lane e1a1f22f13 Forgot that odbc had its own copies of config.sub/config.guess.
Update those to latest Autoconf sources, too.
2000-03-21 06:35:22 +00:00
Thomas G. Lockhart b688f8f034 Fix query for primary keys to reflect new DISTINCT ON () syntax.
Reported by "Tibor Laszlo" <ltibor@mail.tiszanet.hu> and fix suggested by
 "Hiroshi Inoue" <Inoue@tpf.co.jp>.
2000-03-21 06:02:22 +00:00
Thomas G. Lockhart dcdcada7e9 Add syntax for BIT() and BIT VARYING(), but no underlying implementation
is available yet.
Remove redundant call to xlateSqlType() in the character
 type handling code.
2000-03-21 06:00:41 +00:00
Thomas G. Lockhart 3c7ca8d459 Update test for new ORDER BY clause from Tom Lane. 2000-03-21 05:59:14 +00:00
Tom Lane 3ee8f7e207 Restructure planning code so that preprocessing of targetlist and quals
to simplify constant expressions and expand SubLink nodes into SubPlans
is done in a separate routine subquery_planner() that calls union_planner().
We formerly did most of this work in query_planner(), but that's the
wrong place because it may never see the real targetlist.  Splitting
union_planner into two routines also allows us to avoid redundant work
when union_planner is invoked recursively for UNION and inheritance
cases.  Upshot is that it is now possible to do something like
select float8(count(*)) / (select count(*) from int4_tbl)  from int4_tbl
group by f1;
which has never worked before.
2000-03-21 05:12:12 +00:00
Tom Lane aafe86d995 Correct typo in error message. 2000-03-21 04:20:45 +00:00
Bruce Momjian 1d5df1547a This patch corrects spelling, grammar and euphony for the psql reference
page for 7.0:

Oliver Elphick
2000-03-21 01:52:12 +00:00
Bruce Momjian 2216584bcf Reverse out BYTEA type coersion. 2000-03-20 15:42:47 +00:00
Vadim B. Mikheev df238b2c06 Turn XLOG off (do not create log file). 2000-03-20 07:25:39 +00:00
Tom Lane 3caa56fe5e Emit 'this operator is deprecated' warnings for ':' and ';'. 2000-03-20 05:20:34 +00:00
Tom Lane 72b4086711 Convert float8 regress test to use exp() and ln() instead of ':' and
';' operators.
2000-03-20 05:19:11 +00:00
Bruce Momjian 7f116a6b83 Update for BYTEAOID. 2000-03-20 04:26:01 +00:00
Tom Lane 8fc97e8276 Sorry, I have read the misspelling 'coersion' one time too many. 2000-03-20 04:22:11 +00:00
Tom Lane b9a990d8a8 Add exp(), ln(), and some other functions to numeric-functions table. 2000-03-20 04:20:52 +00:00
Tom Lane 339fe3c4cb Add note that ':' and ';' operators are deprecated. 2000-03-20 04:19:47 +00:00
Bruce Momjian 0e1f485f5f Add compatiblity information for bytea. 2000-03-20 04:02:47 +00:00
Hiroshi Inoue fe8098ed0c Add FORCE keyword to ColID 2000-03-20 00:24:37 +00:00
Tom Lane 966b5337e9 Make use of pre-existing regexp match capability to eliminate redundant
entries in template selection rules.  Also, change alpha-dec-osf pattern
to cope with version info attached to the 'alpha' part.
2000-03-19 22:48:30 +00:00
Tom Lane 42ef928327 Autoconf run 2000-03-19 22:46:56 +00:00