Commit Graph

16158 Commits

Author SHA1 Message Date
Bruce Momjian
45de72b683 Add:
> * Allow LISTEN/NOTIFY to store info in memory rather than tables
2003-09-23 21:00:18 +00:00
Bruce Momjian
eed6ff45d4 Add:
* Allow major upgrades without dump/reload, perhaps using pg_upgrade
2003-09-23 20:45:58 +00:00
Tom Lane
aefc08e4eb Minor copy-editing for plpgsql chapter. 2003-09-23 19:58:50 +00:00
Tom Lane
dbf8259adf Tweak generic_type_consistency routines to avoid loss of functionality
since 7.3: 'select array_dims(histogram_bounds) from pg_stats' used to
work and still should.  Problem was that code wouldn't take input of
declared type anyarray as matching an anyarray argument.  Allow this
case as long as we don't need to determine an element type (which in
practice means as long as anyelement isn't used in the function signature).
2003-09-23 17:12:53 +00:00
Tom Lane
267924ead8 _SPI_cursor_operation forgot to check for failure return from
_SPI_begin_call.  Per gripe from Tomasz Myrta.
2003-09-23 15:11:33 +00:00
Michael Meskes
5a5f0a6168 - Changed struct definition handling so "struct foo {}" always gets defined. 2003-09-23 12:56:35 +00:00
Barry Lind
2ec8ee0c0c Fix to properly handle timezone offsets that are partial hours. If the offset
was a partial hour and less than gmt (i.e. -02:30) the code would corrupt the
minutes part.

 Modified Files:
 	jdbc/org/postgresql/jdbc1/AbstractJdbc1Statement.java
2003-09-23 06:13:52 +00:00
Barry Lind
618d56d09a A fix for jdbc regression test submitted yesterday by Kim Ho at Redhat
Modified Files:
 	ResultSetTest.java
2003-09-23 06:11:06 +00:00
Hiroshi Inoue
f5c5c3c6f7 Putting back the previous change must be the first thing.
ALso put back a #ifndef ENABLE_REINDEX_NAILED_RELATIONS
which was removed about a year ago.
2003-09-23 01:51:09 +00:00
Teodor Sigaev
0b1ee9b5a3 fix hlfinditem function. Thanks to "Stphane Bidoul" <stephane.bidoul@softwareag.com>.
The 'word' variable there is initialised from
the prs->words array, but immediately after,
that array may be reallocated, thus leaving
word pointing to unallocated memory.
2003-09-22 13:32:33 +00:00
Michael Meskes
22c0b1f0f4 - Fixed order mismatch in processing "using" arguments.
- Fixed some minor things in test cases.
- Use defines for Informix error codes.
2003-09-22 13:19:39 +00:00
Barry Lind
8839b85ed8 Additional jdbc regression tests submitted by Oliver Jowett. Some tests are
currently commented out, pending fixes for the bugs these tests uncovered.

 Modified Files:
 	jdbc/org/postgresql/test/jdbc2/Jdbc2TestSuite.java
 	jdbc/org/postgresql/test/jdbc2/ServerPreparedStmtTest.java
 Added Files:
 	jdbc/org/postgresql/test/jdbc2/CursorFetchTest.java
2003-09-22 05:38:01 +00:00
Barry Lind
66d00417c9 Applied jdbc patch from Kim Ho at RedHat to improve boolean support, as well
as some additional regression tests for this an other recent changes.

 Modified Files:
 	jdbc/org/postgresql/jdbc1/AbstractJdbc1ResultSet.java
 	jdbc/org/postgresql/test/jdbc2/DateTest.java
 	jdbc/org/postgresql/test/jdbc2/ResultSetTest.java
 	jdbc/org/postgresql/test/jdbc2/TimeTest.java
 	jdbc/org/postgresql/test/jdbc2/TimestampTest.java
2003-09-22 04:55:00 +00:00
Tom Lane
f03d2284c0 HeapTupleSatisfiesVacuum() needs to be more careful about the
difference between INSERT_IN_PROGRESS and DELETE_IN_PROGRESS for
tuples inserted and then deleted by a concurrent transaction.
Example of bug:
regression=# create table foo (f1 int);
CREATE TABLE
regression=# begin;
BEGIN
regression=# insert into foo values(1);
INSERT 195531 1
regression=# delete from foo;
DELETE 1
regression=# insert into foo values(1);
INSERT 195532 1
regression=# create unique index fooi on foo(f1);
ERROR:  could not create unique index
DETAIL:  Table contains duplicated values.
2003-09-22 00:47:23 +00:00
Peter Eisentraut
278a13fe47 Translation updates 2003-09-22 00:27:01 +00:00
Peter Eisentraut
6f57d63cb4 Message wording improvements 2003-09-22 00:23:35 +00:00
Peter Eisentraut
5d00f984d8 Make the SQL command synopses appear less random. 2003-09-22 00:16:58 +00:00
Tom Lane
5aa29e88e9 Arrange to align shared disk buffers on at least 32-byte boundaries,
not just MAXALIGN boundaries.  This makes a noticeable difference in
the speed of transfers to and from kernel space, at least on recent
Pentiums, and might help other CPUs too.  We should look at making
this happen for local buffers and buffile.c too.  Patch from Manfred Spraul.
2003-09-21 17:57:21 +00:00
Tom Lane
11b274f00f Fix some ill-considered ifdefs, per report from Hans-JÏrgen SchÎnig. 2003-09-21 17:42:22 +00:00
Tom Lane
58ad65ec2d Apply ranlib(1) after installing a static (.a) library on Darwin.
Per past complaints --- verified to still be a problem on OS X 10.2.6.
2003-09-20 21:26:20 +00:00
Tom Lane
776ec78e9d Attaching -lpq to LDFLAGS doesn't work, because the generated command
puts that before the .c file name.
2003-09-20 21:14:57 +00:00
Tom Lane
f3ad615ce8 Fix a batch of speling misteaks identified by Peter's spell-checker tool. 2003-09-20 20:12:05 +00:00
Michael Meskes
3438065eed - Renamed my own strndup() function because of a name clash. 2003-09-20 09:10:50 +00:00
Michael Meskes
f604b39c2f - Applied some bug fixing patches by Dave Cramer <dave@fastcrypt.com>.
- Added protecting defines to include files.
2003-09-20 09:10:09 +00:00
Tom Lane
f72a93b4c9 pg_dump missed comments attached to primary key or unique constraints
(as distinct from their underlying indexes).  Per bug report from
Hiroshi Saito.
2003-09-19 23:15:18 +00:00
Tom Lane
8421253e54 Document that TRUNCATE ignores user-defined ON DELETE triggers. 2003-09-19 21:06:39 +00:00
Tom Lane
a13b018530 Disallow foreign-key references from temp tables to permanent tables.
Per recent discussion, this does not work because other backends can't
reliably see tuples in a temp table and so cannot run the RI checks
correctly.  Seems better to disallow this case than go back to accessing
temp tables through shared buffers.  Also, disallow FK references to
ON COMMIT DELETE ROWS tables.  We already caught this problem for normal
TRUNCATE, but the path used by ON COMMIT didn't check.
2003-09-19 21:04:20 +00:00
Tom Lane
fc6b7c550d Latest version of gcc from Apple does not work well with -traditional-cpp
(it rejects some system header files...).  Use -no-cpp-precomp instead.
I think it is okay to change this unconditionally, but if we hear
complaints from people still using very old compilers on Darwin,
we could put in a test to see which switch the compiler likes.
2003-09-19 20:47:59 +00:00
Tom Lane
28847ae77d Seems like a bad idea that REINDEX TABLE supports (or thinks it does)
reindexing system tables without ignoring system indexes, when the
other two varieties of REINDEX disallow it.  Make all three act the same,
and simplify downstream code accordingly.
2003-09-19 19:57:42 +00:00
Michael Meskes
580e08a98b One small typo in preprocessor. 2003-09-19 14:13:16 +00:00
Michael Meskes
df974272ec Removed superfluous return statement in get_data. 2003-09-19 14:06:21 +00:00
Tom Lane
689015748f Put a tad more detail in the discussion of postmaster and postgres
signal handling.
2003-09-18 20:30:15 +00:00
Michael Meskes
723a9bde33 - Accept output variables for FETCH in DECLARE statement.
- Synced parser.
- Allowed C variables to carry the name of prepared statements.
- Added Informix handling of datatype converion errors.
2003-09-18 13:12:23 +00:00
Barry Lind
215d965f0e Applied patch from Oliver Jowett to clean up some instances where the wrong
type was being reported for PREPAREs.

 Modified Files:
 	jdbc/org/postgresql/jdbc1/AbstractJdbc1Statement.java
 	jdbc/org/postgresql/test/jdbc2/ServerPreparedStmtTest.java
2003-09-18 04:14:27 +00:00
Barry Lind
7da6afef26 Small jdbc patch from Kim Ho at RedHat to fix some boolean problems
Modified Files:
 	jdbc/org/postgresql/jdbc1/AbstractJdbc1ResultSet.java
2003-09-18 04:09:02 +00:00
Barry Lind
47cb1c3f94 A minor fix to jdbc regression tests
Modified Files:
 	jdbc/org/postgresql/test/jdbc2/DatabaseMetaDataPropertiesTest.java
2003-09-18 03:58:16 +00:00
Tom Lane
6b73da67b2 Disallow converting a table to a view if it has triggers, indexes, or
child tables --- all cases that will trip various sanity checks elsewhere
in the system, as well as cases that should not occur in the only intended
use of this feature, namely coping with ancient pg_dump representation
of views.  Per bug report from Chris Pizzi.
2003-09-17 17:19:17 +00:00
Barry Lind
e8839c2b6c Applied patch to jdbc from Kim Ho at RedHat, fixing improper handling of empty queries under the V3 protocol
Modified Files:
 	jdbc/org/postgresql/core/QueryExecutor.java
2003-09-17 08:21:36 +00:00
Barry Lind
c020d67bc6 Applied patch for jdbc from Kim Ho at RedHat to more correctly deal with boolean values
Modified Files:
 	jdbc/org/postgresql/jdbc1/AbstractJdbc1ResultSet.java
2003-09-17 07:00:24 +00:00
Barry Lind
292048f186 Fixed jdbc to correctly report that constraints are supported
Modified Files:
 	jdbc/org/postgresql/jdbc1/AbstractJdbc1DatabaseMetaData.java
2003-09-17 06:42:47 +00:00
Barry Lind
33815bf657 Applied patch from Fernando Nasser of RedHat to fix some error messages
that would not get correctly looked up in the translation files for jdbc

 Modified Files:
 	jdbc/org/postgresql/errors.properties
 	jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java
2003-09-17 05:14:52 +00:00
Barry Lind
0671b65b81 Applied patch from Kim Ho at redhat to improve boolean and bit handling
in the jdbc driver

 Modified Files:
 	jdbc/org/postgresql/jdbc1/AbstractJdbc1Statement.java
 	jdbc/org/postgresql/jdbc3/AbstractJdbc3Statement.java
2003-09-17 05:07:38 +00:00
Tatsuo Ishii
ce90c0f504 Fix typo in comment 2003-09-17 04:25:29 +00:00
Tom Lane
7e06dbe1c2 Make psql correctly track the effects of SET CLIENT_ENCODING commands.
I thought I'd fixed this earlier, but I didn't get it right ...
2003-09-16 17:59:02 +00:00
Tatsuo Ishii
7b05ef5b63 fix typo in a comment 2003-09-16 07:47:06 +00:00
Tom Lane
fc73264005 I don't care whether it's informix-compatible or not: #defining a word
like 'date' in a public header file is a damn fool idea.
2003-09-16 04:32:28 +00:00
Tom Lane
b8f8896888 Fix some problems with dropped columns in plpython trigger functions. 2003-09-16 01:07:51 +00:00
Tom Lane
8723e37a26 Since SPI_modifytuple's natts argument is the number of attributes to be
changed, it should allow a zero value (implying no changes to make).
2003-09-16 00:50:09 +00:00
Tom Lane
db18703b5a Fix LISTEN/NOTIFY race condition reported by Gavin Sherry. While a
really general fix might be difficult, I believe the only case where
AtCommit_Notify could see an uncommitted tuple is where the other guy
has just unlistened and not yet committed.  The best solution seems to
be to just skip updating that tuple, on the assumption that the other
guy does not want to hear about the notification anyway.  This is not
perfect --- if the other guy rolls back his unlisten instead of committing,
then he really should have gotten this notify.  But to do that, we'd have
to wait to see if he commits or not, or make UNLISTEN hold exclusive lock
on pg_listener until commit.  Either of these answers is deadlock-prone,
not to mention horrible for interactive performance.  Do it this way
for now.  (What happened to that project to do LISTEN/NOTIFY in memory
with no table, anyway?)
2003-09-15 23:33:43 +00:00
Tom Lane
d73e1b33b5 Update regression test for message change. 2003-09-15 23:25:31 +00:00