RowExclusive (my fault). Also, install a check to prevent people
from trying COPY BINARY to stdout/from stdin. No way that will
work unless we redesign the frontend COPY protocol ... which is
not worth the trouble in the near future ...
is in <string> and not in <string.h> on QNX4/egcs-2.91.60.
Probably this can be changed for all platforms. The test in line 1705 uses
<string> as well. Because I am not sure, I havn't this included into the
patch.
doc/Makefile has to be sligthly modified as it has been done for
src/backend/Makefile due to a QNX4 problem (patch attached)
Furthermore src/test/regress/run_check.sh needs to be patched as it has been
done for regress.sh (patch attached). Please note that in the patch the
postmaster is started always with the -i option.
run_check.sh reports the test "limit" as failed, but in reallity it is OK.
regress.sh reports it as OK.
Andreas Kardos
IRIX systems using the native compilers. A summary is:
- Various files use "//" as a comment delimiter in c files.
- Problems caused by assuming "char" is signed.
cash.in: building -signed the rules regression test fails as described
in FAQ_QNX4. If CHAR_MAX is "255U" then ((signed char)CHAR_MAX) is -1.
postmaster.c: random number regression test failed without this change.
- Some generic build issues and warning message cleanup.
David Kaelbling
just use the portable form,
tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz
There were a bunch of places that weren't paying attention to configure's
result anyway (including configure itself!?); clean them up too.
I'm including a diff of
postgresql-7.0/src/interfaces/jdbc/org/postgresql/jdbc2/ResultSet.java.
I've clearly marked all the fixes I did. Would *someone* who has access
to the cvs please put this in?
Joseph Shraibman
days. It seems to be a FAQ, and I think I know why. When creating a 'c'
language function, CREATE FUNCTION is fed the shared object filename,
and seems to succeed. Only when trying to use the function is an error
thrown, by which time the coder thinks something's wrong with executing
the code, not with loading it.
I think I once saw it proposed to load shared objects at function creation
time, but that idea was shot down on the grounds of resident memory bloat,
ISTR. Here's a patch for a compromise: all it does is stat() the file,
just like the loader code does, so that the errors caused by non existent
files, and no directory 'x' permissions (the most common ones, it seems),
get caught while the developer is still thinking about code loading. It
doesn't catch all errors (like the code not being readable by the postgres
user) but seems to catch the most common, without actually opening the file.
What do you think?
Ross
indexes, apparently, nor on functional indexes with more than one input
column (force of natts = 1 was in the wrong branch of IF statement).
Coredumped if source relation contained any uncommitted tuples, due to
failure to test for success return from heap_fetch. Fetched tuple
was passed directly to heap_insert, which clobbers the TID and commit
status in the tuple header it's given, which meant that the source
relation's tuples all got trashed as the copy proceeded. Abort partway
through, and you're left with a lot of missing tuples.
I wonder what else is lurking here ...
under FreeBSD ... basically, if setproctitle() exists, use it ...
the draw back right now is the PS_SET_STATUS stuff doesn't work, but am looking
into that one right now ... at lesat now you can see who is connecting where
and from where ...
mappings. In fact, it had them backward because it was using the 6.5.*
code. Copied them from parser/gram.y, so it is fixed now. Looks like
our first 7.0.1 fix. Oops, seems Tom has beat me to it as I was typing
this.
Rearrange handling of VACUUMs so that they are certain to be executed
as superuser not some random user; also, do not forget to vacuum
template1 itself.
pg_char_to_encoding() in multibyte disbaled case so that it does not
throw an error, rather return HARD CODED default value (currently SQL_ASCII).
This would solve the "non-mb backend vs. mb-enabled frontend" problem.
cleanup, ie, as soon as we have caught the longjmp. This ensures that
current context will be a valid context throughout error cleanup. Before
it was possible that current context was pointing at a context that would
get deleted during cleanup, leaving any subsequent pallocs in deep
trouble. I was able to provoke an Assert failure when compiled with
asserts + -DCLOBBER_FREED_MEMORY, if I did something that would cause
an error to be reported by the backend large-object code, because indeed
that code operates in a context that gets deleted partway through xact
abort --- and CurrentMemoryContext was still pointing at it! Boo hiss.
cases where joinclauses were present but some joins have to be made
by cartesian-product join anyway. An example is
SELECT * FROM a,b,c WHERE (a.f1 + b.f2 + c.f3) = 0;
Even though all the rels have joinclauses, we must join two of them
in cartesian style before we can use the join clause...
than BIND_DEFERRED. That way, if the loaded library has unresolved
references, shl_load fails cleanly. As we had it, shl_load would
succeed and then the dynlinker would call abort() when we try to call
into the loaded library. abort()ing a backend is uncool.
always failed if Perl makefile's INSTALLSITELIB variable was specified
in terms of another variable. Fix by adding an echo-installdir target
to the Perl makefile, which the upper-level Makefile can invoke.
libpq++.h contained copies of the class declarations in the other libpq++
include files, which was bogus enough, but the declarations were not
completely in step with the real declarations. Remove these in favor
of including the headers with #include. Make PgConnection destructor
virtual (not absolutely necessary, but seems like a real good idea
considering the number of subclasses derived from it). Give all classes
declared private copy constructors and assignment operators, to prevent
compiler from thinking it can copy these objects safely.
compiler than the one selected to build Postgres with. It was trying
to feed Postgres-compiler switches to Tcl's compiler. (Seen this before
with the perl5 interface...) Fix to use only CFLAGS taken from Tcl's
configure information, plus -I which is pretty universal.
unless you feed it -Aa or -Ae switch. Autoconf does not know about this,
but we can fix it in the hpux_cc template file. I knew templates were
good for something ;-)
to give wrong results: it should be looking at inJoinSet not inFromCl.
Also, make 'modified' flag be local to ApplyRetrieveRule: we should
append a rule's quals to the query iff that particular rule applies,
not if we have fired any previously-considered rule for the query!
(SELECT FROM table*). Cause was reference to 'eref' field of an RTE,
which is null in an RTE loaded from a stored rule parsetree. There
wasn't any good reason to be touching the refname anyway...
table for an average of NTUP_PER_BUCKET tuples/bucket, but cost_hashjoin
was assuming a target load of one tuple/bucket. This was causing a
noticeable underestimate of hashjoin costs.
(LIKE and regexp matches). These are not yet referenced in pg_operator,
so by default the system will continue to use eqsel/neqsel.
Also, tweak convert_to_scalar() logic so that common prefixes of strings
are stripped off, allowing better accuracy when all strings in a table
share a common prefix.
subsequent elogs() in the same COPY operation to display the wrong
line number. Fix is to clear lineno only when elog level is such
that we will not return to caller.
repaired psql option scanning bug (special treatment to \g |pipe)
fixed ipcclean makefile
made configure look for Perl to handle psql help build gracefully
extern int inet_aton(const char *cp, struct in_addr * addr);
appearing before the optional #define for const, which was certain
to fail on a machine with neither const nor inet_aton().
compiler will understand them. configure may have #define'd them to
empty because the local C compiler doesn't understand them, but this
may very well cause a C++ compilation to fail, so don't do it in C++.
all platforms, not just SCO. The operation is undefined for Unix-domain
sockets anyway. It seems SCO is not the only platform that complains
instead of treating the call as a no-op.
include the version from backend/port into libpq.
There is a second-rate implementation of inet_aton() already present
in fe-connect.c, #ifdef'd WIN32. That ought to be removed in favor
of using the better version from port/. However, since I'm not in a
position to test the WIN32 code, I will leave well enough alone for
this release...
contained a sub-SELECT nested within an AND/OR tree that cnfify()
thought it should rearrange. Same physical sub-SELECT node could
end up linked into multiple places in resulting expression tree.
This is harmless for most node types, but not for SubLink.
Repair bug by making physical copies of subexpressions that get
logically duplicated by cnfify(). Also, tweak the heuristic that
decides whether it's a good idea to do cnfify() --- we don't really
want that to happen when it would cause multiple copies of a subselect
to be generated, I think.
whether to do fsync or not, and if so (which should be seldom) just
do the fsync immediately. This way we need not build data structures
in md.c/fd.c for blind writes.
logged queries to 1024, truncating longer queries. That is about half of
the size I need (I have a union that is 2K long). Can someone consider
bumping it to 4K or so? Patch attached...
Regards,
Ed Loehr
as a shared dirtybit for each shared buffer. The shared dirtybit still
controls writing the buffer, but the local bit controls whether we need
to fsync the buffer's file. This arrangement fixes a bug that allowed
some required fsyncs to be missed, and should improve performance as well.
For more info see my post of same date on pghackers.
than not knowing what they are at all. Perhaps they should have their own
type category? Hard to say. In the meantime, doing it this way allows
SELECT 'unknown' || 'unknown' to continue being resolved as textcat,
instead of spitting out an ambiguous-operator error.
parse node types. This allows these statements to be placed in a plpgsql
function. Also, see to it that statement types not handled by the copy
logic will draw an appropriate elog(ERROR), instead of leaving a null
pointer that will cause coredump later on. More utility statements could
be added if anyone felt like turning the crank.
Add a random number generator and seed setter (random(), SET SEED)
Fix up the interval*float8 math to carry partial months
into the time field.
Add float8*interval so we have symmetry in the available math.
Fix the parser and define.c to accept SQL92 types as field arguments.
Fix the parser to accept SQL92 types for CREATE TYPE, etc. This is
necessary to allow...
Bit/varbit support in contrib/bit cleaned up to compile and load
cleanly. Still needs some work before final release.
Implement the "SOME" keyword as a synonym for "ANY" per SQL92.
Implement ascii(text), ichar(int4), repeat(text,int4) to help
support the ODBC driver.
Enable the TRUNCATE() function mapping in the ODBC driver.
Ensure that outer tuple link needed for inner indexscan qual evaluation
gets set in the EvalPlanQual case. This stops coredump, but we still
have resource leaks due to failure to clean up EvalPlanQual properly...
It does work with the following patch applied and gcc 2.95.2 .
Use --with-template=aix_gcc to compile the whole lot with gcc.
The geometry regression test produces different precision.
With optimization I run into regression failures starting at oidjoins,
thus no -O2. Anybody else try gcc 2.95.2 and -O2 on beta4 ?
This is an important patch, since recent versions of the IBM compiler
are not for free, and thus most questions I get concern gcc.
Andreas
PS.: I am testing with beta4
xact abort state in pg_exec_query_dest, we should continue scanning the
querytree list, on the off chance that one of the later queries in the
string is COMMIT or ROLLBACK.
would crash, due to premature invocation of SetQuerySnapshot(). Clean
up problems with handling of multiple queries by splitting
pg_parse_and_plan into two routines. The old code would not, for
example, do the right thing with END; SELECT... submitted in one query
string when it had been in transaction abort state, because it'd decide
to skip planning the SELECT before it had executed the END. New
arrangement is simpler and doesn't force caller to plan if only
parse+rewrite is needed.
be an expression not just a simple Var, so long as only one table is
referenced (so that code isn't really any more difficult than before).
This whole thing is still fundamentally bogus, but at least we can accept
a few more cases than before.
WHERE in a place where it can be part of a nestloop inner indexqual.
As the code stood, it put the same physical sub-Plan node into both
indxqual and indxqualorig of the IndexScan plan node. That confused
later processing in the optimizer (which expected that tracing the
subPlan list would visit each subplan node exactly once), and would
probably have blown up in the executor if the planner hadn't choked first.
Fix by making the 'fixed' indexqual be a complete deep copy of the
original indexqual, rather than trying to share nodes below the topmost
operator node. This had further ramifications though, because we were
making the aforesaid list of sub-Plan nodes during SS_process_sublinks
which is run before construction of the 'fixed' indexqual, meaning that
the copy of the sub-Plan didn't show up in that list. Fix by rearranging
logic so that the sub-Plan list is built by the final set_plan_references
pass, not in SS_process_sublinks. This may sound like a mess, but it's
actually a good deal cleaner now than it was before, because we are no
longer dependent on the assumption that planning will never make a copy
of a sub-Plan node.
Should be more robust to overflows.
Pass through an unmapped function unchanged, rather than rejecting it.
Add a few more functions, but comment out those which can go through as-is.
Can be used with contrib/odbc/ package, though that isn't committed yet.
here is an updated version of the bit type with a bugfix and all the necessa
ry
SQL functions defined. This should replace what is currently in contrib. I'd
appreciate any comments on what is there.
Kind regards,
Adriaan
pg_internal.init file in-place, which meant that if another backend
started at about the same time, it might read the incomplete file.
init_irels tries to guard against that, but I have now seen a crash
due to reading bad data from a partly-written file. (This may indicate
a kernel bug on my platform? Not sure.) Anyway, clearly the safest
course is to write the new pg_internal.init file under a unique temporary
filename, and rename it into place only after it's all written.
- I was unable to compile ecpg due to the ":=" instead of "=" in defining
LIBPQDIR and some other variables in Makefile.global.in
- pg_id (and also pg_encoding) executable was not removed during "make
clean" - there was no $(X) appended to the executable name for rm
- I have added result for int2, int4, float8 and geometry regression tests
- int2, int2 - yet another message for too large numbers ;-)
- float8 - it is problably a bug in the newlib C library - it has no
error message for numbers with exponent -400
- geometry - differences in precision of float numbers
- I have added appropriate lines into resultmap file
- I have modified the script regress.sh to use "case" statement when testing
the hostname. For cygwin the script is called with "i686-pc-cygwin" (on my
machine) as a parameter and this was not catched with the "if" statement.
The check was done for PORTNAME (win) and not HOSTNAME (i.86-pc-cygwin*).
The patch for described modifications is included.
All this modifications can be applied to "current" tree too.
The compilation was done on CygwinB20.1 with gcc 2.95, cygipc library 1.05.
The binaries were able to run also on the newest development snapshot
(2000-03-25).
Dan
Make similar changes to hpux templates. Might want to do the same for
other foo_cc and foo_gcc pairs, but will desist until I hear from
someone who uses those platforms.
and do not arbitrarily pull in CFLAGS instead. This caters to platforms
where the C++ compiler does not like all the same switches the C compiler
wants.
In the event of an elog() while the mode was set to immediate write,
there was no way for it to be set back to the normal delayed write.
The mechanism was a waste of space and cycles anyway, since the only user
was varsup.c, which could perfectly well call FlushBuffer directly.
Now it does just that, and the notion of a write mode is gone.
single integers, and lists of names, without surrounding them with quotes.
Remove all tokens which are defined as operators from ColID and ColLabel
to avoid precedence confusion. Thanks to Tom Lane for catching this.
to next integer. Previously, if selectivity was small, we could compute
very tiny scan cost on the basis of estimating that only 0.001 tuple
would be fetched, which is silly. This naturally led to some rather
silly plans...
Move CREATE FUNCTION/WITH clause to end of statement to get around
shift/reduce conflicts with type names containing "WITH".
Add lots of tokens as allowed ColId's and/or ColLabel's,
so this should be a complete set for the v7.0 release.
We still have an internal limit in the ODBC code of 8 columns per key,
but this should lay the groundwork for resolving that.
Includes reformulated query from Tom Lane.
apparently copied from the makefile for the perl5 interface module,
which needs it for reasons explained in src/interfaces/Makefile.
But none of those reasons apply to plperl.
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)
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...
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.
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.
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
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.
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.
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.
command, the entries in template/.similar can really be regular
expressions. This isn't a new feature, just an observation of what the
code already did.
had already been transformed. This led to failure in examples like
UPDATE table SET fld = (SELECT ...). Repair this, and revise the
comments to explain that transformExpr has to be robust against this
condition. Someday we might want to fix the callers so that
transformExpr is never invoked on its own output, but that someday
is not today.
user, so it doesn't need to be translated from the number to the name.
also ``create database ...'' does not take numbers for the encoding, so
the ENCODING variable does not need to be translated to a number, but left
as the text representation. a patch is supplied to make the changes i
have found to work. i was successful dumping and reloading my database
after these changes.
-
John M. Flinchbaugh
incorrect descriptions of a couple of log-related functions.
I will not force an initdb for this, but log() on a numeric won't
work until you do one...
In function parsing, try for an actual function of the given name and
input types before trying to interpret the function call as a type
coercion request, rather than after. Before, a function that had the
same name as a type and operated on a binary-compatible type wouldn't
get invoked. Also, cross-pollinate between func_select_candidates and
oper_select_candidates to ensure that they use as nearly the same
resolution rules as possible. A few other minor code cleanups too.
problem could be lack of parentheses. This addresses cases like
X UserOp UserOp Y, which will be parsed as (X UserOp) UserOp Y,
whereas what likely was wanted was X UserOp (UserOp Y).
16-Mar-00: trailing + or - is not part of the operator unless the operator
also contains characters not present in SQL92-defined operators. This
solves the 'X=-Y' problem without unduly constraining users' choice of
operator names --- in particular, no existing Postgres operator names
become invalid.
Also, remove processing of // comments, as agreed in the same thread.
running gcc and HP's cc with warnings cranked way up. Signed vs unsigned
comparisons, routines declared static and then defined not-static,
that kind of thing. Tedious, but perhaps useful...
/tmp/trace.out.
However, elog.h uses DEBUG as a log-level flag. As a result, tracing is
turned on even if the libpq++.so is built with DEBUG commented out in
the Makefile.
This patch changes libpq++ to use DEBUGFILE instead (which is not
defined anywhere else).
Oliver Elphick
We probably support a superset of the spec, but I don't have the spec
to confirm this.
Update regression tests to include tests for this format.
Update geometry.out with results from Linux RH 5.2 system
(for last decimal place).
We probably support a superset of the spec, but I don't have the spec
to confirm this.
Update regression tests to include tests for this format.
Fix single-space typo in printed message in regress.sh.
actually a type-coercion problem. If you have a function defined on
class A, and class B inherits from A, then the function ought to work
on class B as well --- but coerce_type didn't know that. Now it does.
mark query as having subselects if a subselect was added from a rule
WHERE condition (as opposed to a rule action). Also, fix adjustment
of varlevelsup so that it actually has some prospect of working when
inserting an expression containing a subselect into a subquery.
small changes in formatting.c code (better memory usage ...etc.) and
better
to_char's cache (will fastly for more to_char()s in one query).
(It is probably end of to_char() development in 7.0 cycle.)
Karel
after trying to resolve the item as an input-column name. This allows us
to be compliant with the SQL92 spec for queries that fall within the spec,
while still accepting the same out-of-spec queries as 6.5 did. You'll only
lose if there is an output column name that is the same as an input
column name, but doesn't refer to the same value. 7.0 will interpret
such a GROUP BY spec differently than 6.5 did. No way around that, because
6.5 was clearly not spec compliant.
CREATE DB/DROP DB. If you didn't think they were wrong, try what
happens when you compile with -DCLOBBER_FREED_MEMORY --- database
name displayed in error messages is trashed, because transaction
abort freed it. Also, remove trailing periods in error messages,
per our prevailing style.
Implement TIME WITH TIME ZONE type (timetz internal type).
Remap length() for character strings to CHAR_LENGTH() for SQL92
and to remove the ambiguity with geometric length() functions.
Keep length() for character strings for backward compatibility.
Shrink stored views by removing internal column name list from visible rte.
Implement min(), max() for time and timetz data types.
Implement conversion of TIME to INTERVAL.
Implement abs(), mod(), fac() for the int8 data type.
Rename some math functions to generic names:
round(), sqrt(), cbrt(), pow(), etc.
Rename NUMERIC power() function to pow().
Fix int2 factorial to calculate result in int4.
Enhance the Oracle compatibility function translate() to work with string
arguments (from Edwin Ramirez).
Modify pg_proc system table to remove OID holes.
(ie, allow rounding to occur at a digit position left of the decimal
point). Apparently this is how Oracle handles it, and there are
precedents in other programming languages as well.
Since we detect oversize tuples elsewhere, I see no reason not to allow
string constants that are 'too long' --- after all, they might never get
stored in a tuple at all.
YY_READ_BUF_SIZE, which turns out to have nothing to do with buffer size.
It's just a totally arbitrary upper limit on how much data myinput() is
asked for at one time.
that the inputs to a given operator can be recursively simplified to
constants, it was evaluating the operator using the op's *original*
(unsimplified) arg list, so that any subexpressions had to be evaluated
again. A constant subexpression at depth N got evaluated N times.
Probably not very important in practical situations, but it made us look
real slow in MySQL's 'crashme' test...
gone, replaced by plain a_expr. The few places where we needed to
distinguish NULL from a_expr are now handled by tests inside the actions
rather than by separate productions. This allows us to accept queries
like 'SELECT 1 + NULL' without requiring parentheses around the NULL.
subplan: do it if subplan has subplans itself, and always do it if the
subplan is an indexscan. (I originally set it to materialize an indexscan
only if the indexqual is fairly selective, but I dunno what I was
thinking ... an unselective indexscan is still expensive ...)
coercion code. I'm beginning to wonder why we have separate candidate
selection routines for functions, operators, and aggregates --- shouldn't
this code all be unified? But meanwhile,
SELECT 'a' LIKE 'a';
finally works; the code for dealing with unknown input types for operators
was pretty busted.
per pghackers discussion around 20-Feb. Also add specific error messages
for unterminated comments and unterminated quoted strings. These things
are nonissues for input coming from psql, but they do matter for input
coming from other front ends.
array. This allows processing of conninfo strings to be made thread-safe,
at the cost of a small memory leak in applications that use
PQconndefaults() and are not updated to free the returned array via
the new PQconninfoFree() function. But PQconndefaults() is probably not
used very much, so this seems like a good compromise.
nodes. The former version failed to check permissions of relations that
were referenced in second and later clauses of UNIONs, and it did not
check permissions of tables referenced via inheritance.
The regression test script runcheck.sh doesn't seem able to
handle the blank line on the end of the resultmap file.
Here's a patch to remove it!!
Keith.
1) adds NetBSD shared lib support on both ELF and a.out platforms
2) replaces "-L$(LIBPQDIR) -lpq" with "$(LIBPQ)" defined in
Makefile.global. This makes it much easier to build stuff in
the source tree after you've already installed the libraries.
3) adds TEMPLATEDIR in Makefile.global that indicates where the
database templates are stored. This separates the template files
from real libraries that are installed in $(LIBDIR).
4) changes include order of <readline/readline.h> and <readline.h>.
The latest GNU readline installs its headers under a readline
subdirectory.
In addition to applying the patch below the following files need to be copied:
backend/port/dynloader:
bsd.h -> netbsd.h
bsd.c -> netbsd.c
include/port:
bsd.h -> netbsd.h
makefiles:
Makefile.bsd -> Makefile.netbsd
It would be great to see this incorporated into the source tree before
the 7.0 release is cut.
Thanks!
-- Johnny C. Lam <lamj@stat.cmu.edu>
Here's a patch to fix the " '.' not allowed in db path" problem I ran into.
I removed '.' from the set of illegial characters, but added backtick. I also
included an explicit test for attempting include a reference to a parent dir.
How that?
Ross
I try change prompt in the psql, but it is set '.' (as '%m') for
non-TCP/IP
connection. This small patch try use uname() information for non-TCP/IP
instead '.'.
Karel
the to_char() source code is large, here are regression tests for
numeric/timestamp/int8 part. It is probably enough test for formatting
code in the formatting.c module. The others (float4/float8/int4) types
share this formatting code and eventual bugs for these types aren't
few probable.
Patch fix timestamp_to_char() for infinity/invalid timestamp too.
Karel
(Subj: [PORTS] initdb problem on NT with 7.0). Since nobody helped me,
I had to find out the reson. The difference between NT and Linux (for
instance) is that "open( path, O_RDWR );" opens a file in text mode. So
sometime less block can be read than required.
I suggest a following patch. BTW the situation appeared before, see
hba.c, pqcomm.c and others.
Alexei Zakharov
when you have networks with the same prefix, but different netmasks.
This is due to the fact that occassionally there is random
(uninitialized?)
data in the extra bits past the point where the netmask cares about
them.
ie (real data from a real live database):
10.0/10 == 00001010.00100000.00100000.00011000
10.0/11 == 00001010.00000000.00000000.00000000
^ Bad data, normally never seen
The v4bitncmp() function was only taking one bit length argument so
it would determine that the networks were different, even though
they really aren't (and the netmask test wouldn't be used). This
ONLY happens if the tuple with the longer bit length is used as the
ip_bits() for the v4bitncmp call AND there happens to be junk data
in place in the shorter tuple. Odd and random, but I saw it happen
a couple times so...
Ryan Mooney
as independent clauses in the grammar. analyze.c takes care of putting
the data where it belongs and complaining about invalid combinations.
Also, make TEMP (and TEMPORARY) non-reserved words.
failures. Fix some outright bugs too, including a reference to
uninitialized memory that would cause failures like this one:
select -('1234567890.1234567'::text);
ERROR: Unable to locate type oid 2139062143 in catalog
such as bpchar(char_expression, N), and pull out the attrtypmod that
the function is coercing to. This allows correct deduction of the
column type in examples such as
CREATE VIEW v AS SELECT f1::char(8) FROM tbl;
Formerly we labeled v's column as char-of-unknown-length not char(8).
Also, this change causes the parser not to insert a redundant length
coercion function if the user has explicitly casted an INSERT or UPDATE
expression to the right length.
fields, nor with bpchar and varchar fields that have typmod -1. The
latter effectively have an unspecified length, so I made them display
as char() and varchar() rather than falsely equating them to char(1)
and varchar(1).
it's a good idea to choose the directory size based on the expected
number of entries. But ShmemInitHash was using a hard-wired constant.
Boo hiss. This accounts for recent report of postmaster failure when
asking for 64K or more buffers.
platform (psql and libpq):
The file "config.h.win32" in the include\ directory (from my patch from
2000-01-18) is missing from the tree. It needs to be put back :-)
The following patch has to be applied in the interfaces\libpq directory.
//Magnus
thinks the connection is idle, the error message is displayed as if
it were a NOTICE. This seems better than dropping the message on
the floor ... particularly if the message is the backend telling us
why it's about to close the connection. The previous behavior was
Backend message type 0x45 arrived while idle
pqReadData() -- backend closed the channel unexpectedly.
which is not real helpful.
as a unary minus operator for numeric. Now that long numeric constants
will get converted to NUMERIC in early parsing, it's essential to have
numeric->int8 conversion to avoid 'can't convert' errors on undecorated
int8 constants. Threw in the rest for completeness while I was in the
area.
I did not force an initdb for this, since the system will still run
without the new pg_proc/pg_operator entries. Possibly I should've.
and produce either FLOAT8 or NUMERIC output depending on whether the
value fits in a float8 or not. This is almost back to the way the
code was before I changed T_Float, but there is a critical difference:
now, when a numeric constant doesn't fit in float8, it will be treated
as type NUMERIC instead of type UNKNOWN.
2. Regression tests fail for types int2 and int4 (which can easily be
fixed by adding entries to resultmap) aswell as float8 and geometry,
where floating point numbers appear to be rounded a little differently
than in your expected results (besides that I also need the positive
zeros file). I'm including a patch for the first 2, but I don't know
whether the latter two are actually a bug in postgres or a bug in the
OS or even allowed difference. I'm including my results for reference.
Rolf Grossmann
tests for the Foreign Key support in 7.0 which
was made against a CVS copy from this
afternoon.
This modifies
src/test/regress/sql/run_check.tests
src/test/regress/sql/alter_table.sql
src/test/regress/expected/alter_table.out
src/test/regress/sql/foreign_key.sql
src/test/regress/expected/foreign_key.out
sszabo@bigpanda.co