TODO 14.0 KB
Newer Older
B
Bruce Momjian 已提交
1 2
TODO list for PostgreSQL
========================
B
Bruce Momjian 已提交
3
Last updated:		Tue Feb 22 09:07:16 EST 2000
M
Marc G. Fournier 已提交
4

B
Bruce Momjian 已提交
5
Current maintainer:	Bruce Momjian (pgman@candle.pha.pa.us)
M
Marc G. Fournier 已提交
6

B
Bruce Momjian 已提交
7
The most recent version of this document can be viewed at
B
Bruce Momjian 已提交
8
the PostgreSQL web site, http://www.PostgreSQL.org.
B
Bruce Momjian 已提交
9

B
Bruce Momjian 已提交
10
A dash(-) marks changes that will appear in the upcoming 7.0 release.
B
Bruce Momjian 已提交
11

B
Bruce Momjian 已提交
12 13 14
Names in brackets "[]" indicate more detailed information is available in
the directory pgsql/doc/TODO.detail/ under that name.

B
Bruce Momjian 已提交
15

M
Marc G. Fournier 已提交
16 17
RELIABILITY
-----------
B
Bruce Momjian 已提交
18 19 20

RESOURCES

B
Bruce Momjian 已提交
21
* -Disallow inherited columns with the same name as new columns
B
Bruce Momjian 已提交
22
* -Elog() does not free all its memory
B
Bruce Momjian 已提交
23
* -spinlock stuck problem when elog(FATAL) and elog(ERROR) inside bufmgr
B
Bruce Momjian 已提交
24
* -Recover or force failure when disk space is exhausted(Hiroshi)
B
Bruce Momjian 已提交
25 26 27

PARSER

B
Bruce Momjian 已提交
28
* -INSERT INTO ... SELECT with AS columns matching result columns problem
B
Bruce Momjian 已提交
29
* SELECT pg_class FROM pg_class generates strange error
B
Bruce Momjian 已提交
30
* Alter TABLE ADD COLUMN does not honor DEFAULT, add CONSTRAINT
B
Bruce Momjian 已提交
31 32
* -Select a[1] FROM test fails, it needs test.a[1](Tom)
* -Array index references without table name cause problems [array](Tom)
33
* Creating index of TIMESTAMP & RELTIME fails, or rename to DATETIME(Thomas)
B
Bruce Momjian 已提交
34
* SELECT foo UNION SELECT foo is incorrectly simplified to SELECT foo
B
Bruce Momjian 已提交
35 36
* -INSERT ... SELECT ... GROUP BY groups by target columns not source columns(Tom)
* -CREATE TABLE test (a char(5) DEFAULT text '', b int4) fails on INSERT(Tom)
B
Bruce Momjian 已提交
37
* -UNION with LIMIT fails
B
Bruce Momjian 已提交
38 39
* Unique index on base column not honored on inserts from inherited table
  INSERT INTO inherit_table (unique_index_col) VALUES (dup) should fail
B
Bruce Momjian 已提交
40
  [inherit] 
B
Bruce Momjian 已提交
41 42 43
* -CREATE TABLE x AS SELECT 1 UNION SELECT 2 fails
* -CREATE TABLE test(col char(2) DEFAULT user) fails in length restriction
* -mismatched types in CREATE TABLE ... DEFAULT causes problems [default]
B
Bruce Momjian 已提交
44 45 46
* -SELECT ... UNION ... ORDER BY fails when sort expr not in result
  list, ORDER BY is applied only to the first SELECT

B
Bruce Momjian 已提交
47
* Be smarter about promoting types when UNION merges different data types
B
Bruce Momjian 已提交
48
* redesign INSERT ... SELECT to have two levels of target list
B
Bruce Momjian 已提交
49
* -select * from pg_class where oid in (0,-1)
B
Bruce Momjian 已提交
50
* have INTERSECT/EXCEPT prevent duplicates unless ALL is specified
B
Bruce Momjian 已提交
51
* -prevent primary key that exceeds max index columns [primary]
B
Bruce Momjian 已提交
52
* -SELECT COUNT('asdf') FROM pg_class WHERE oid=12 crashes
B
Bruce Momjian 已提交
53
* SELECT DISTINCT ON col1 col1 col2 FROM tab1 is broken [distinct]
B
Bruce Momjian 已提交
54
* -require SELECT DISTINCT target list to have all ORDER BY columns
B
Bruce Momjian 已提交
55
* -When using aggregates + GROUP BY, no rows in should yield no rows out(Tom)
B
Bruce Momjian 已提交
56
* -Allow HAVING to use comparisons that have no aggregates(Tom)
B
Bruce Momjian 已提交
57
* -Allow COUNT(DISTINCT col))(TOm)
B
Bruce Momjian 已提交
58 59
* SELECT 'x'::varchar(10) INTO newtable; fails
* SELECT col::DECIMAL(12,10); fails
B
Bruce Momjian 已提交
60 61 62 63

VIEWS

* Views containing aggregates sometimes fail(Jan)
B
Bruce Momjian 已提交
64
* -Views with spaces in view name fail when referenced
65 66
* Creating view and inheriting the view causes view* to show
  duplicates(inherit) 
B
Bruce Momjian 已提交
67
* Disallow LOCK on view
B
Bruce Momjian 已提交
68

B
Bruce Momjian 已提交
69 70
MISC

B
Bruce Momjian 已提交
71
* -User who can create databases can modify pg_database table(Peter E)
B
Bruce Momjian 已提交
72
* Plpgsql does not handle quoted mixed-case identifiers
B
Bruce Momjian 已提交
73
* -Fix btree to give a useful elog when key > 1/2 (page - overhead)(Tom)
B
Bruce Momjian 已提交
74
* -pg_dump should preserve primary key information
B
Bruce Momjian 已提交
75
* plpgsql regression tests fails on BSD/OS
76
* -database names with spaces fail
B
Bruce Momjian 已提交
77
* -insert of 0.0 into DECIMAL(4,4) field fails(Tom)
B
Bruce Momjian 已提交
78
* -* Interlock to prevent DROP DATABASE on a database with running backendsInterlock to prevent DROP DATABASE on a database with running backends
B
Bruce Momjian 已提交
79 80
* Buffer reference counting bugfixes
* Fix libpq bug that causes it to drop backend error message sent
B
Bruce Momjian 已提交
81 82
  just before connection closure (ie, any FATAL error message)
* SELECT ... UNION ... ORDER BY fails when sort expr not in result list
B
Bruce Momjian 已提交
83 84
* SELECT ... UNION ... GROUP BY fails if column types disagree, no type
  promotion occurs
B
Bruce Momjian 已提交
85 86
* Modification  of  pg_class  can  happen while table in use by
  another backend.  Might  lead  to  MVCC  inside  of  syscache
M
Marc G. Fournier 已提交
87 88 89

ENHANCEMENTS
------------
B
Bruce Momjian 已提交
90 91 92

URGENT

B
Bruce Momjian 已提交
93
* -Add referential integrity(Jan)[primary]
B
Bruce Momjian 已提交
94 95 96
* Add MATCH PARTIAL referential integrity
* Foreign key does not check that columns referenced form a primary key
  or constrained by UNIQUE 
B
Bruce Momjian 已提交
97
* Add OUTER joins, left and right[outer](Thomas, Bruce)
B
Bruce Momjian 已提交
98
* Allow long tuples by chaining or auto-storing outside db (TOAST)(Jan)
B
Bruce Momjian 已提交
99
* -Eliminate limits on query length
B
Bruce Momjian 已提交
100 101
* Fix memory leak for expressions[memory](Tom?) 
* -Fix memory leak for aggregates(Tom)
B
Bruce Momjian 已提交
102

B
Bruce Momjian 已提交
103 104
ADMIN

B
Bruce Momjian 已提交
105
* -Better interface for adding to pg_group(Peter E)
B
Bruce Momjian 已提交
106
* More access control over who can create tables and access the database
B
Bruce Momjian 已提交
107
* Test syslog functionality
B
Bruce Momjian 已提交
108 109
* Allow elog() to return error codes, not just messages
* Allow international error message support and add error codes
B
Bruce Momjian 已提交
110
* -Generate postmaster pid file and remove flock/fcntl lock code[flock](Tatsuo)
B
Bruce Momjian 已提交
111
* Add ability to specifiy location of lock/socket files [flock]
B
Bruce Momjian 已提交
112
* Unify configuration into one configuration file
B
Bruce Momjian 已提交
113

B
Bruce Momjian 已提交
114 115
TYPES

B
Bruce Momjian 已提交
116
* -Add BIT, BIT VARYING
B
Bruce Momjian 已提交
117 118 119
* Nchar (as distinguished from ordinary varchar),
* Domain capability
* Add STDDEV/VARIANCE() function for standard deviation computation/variance
B
Bruce Momjian 已提交
120
* Allow compression of large fields or a compressed field type
B
Bruce Momjian 已提交
121
* Large objects
B
Bruce Momjian 已提交
122
	o Fix large object mapping scheme, own typeid or reltype(Peter)
B
Bruce Momjian 已提交
123 124
	o Not to stuff everything as files in a single directory, hash dirs
	o Allow large object vacuuming
125
	o Tables that start with xinv confused to be large objects
B
Bruce Momjian 已提交
126
* -Allow pg_descriptions when creating tables
B
Bruce Momjian 已提交
127
* -Allow pg_descriptions when creating types, columns, and functions
B
Bruce Momjian 已提交
128 129 130 131
* Add IPv6 capability to INET/CIDR types
* Make a separate SERIAL type?
* Store binary-compatible type information in the system
* Add support for & operator
B
Bruce Momjian 已提交
132
* Allow LOCALE on a per-column basis, default to ASCII
B
Bruce Momjian 已提交
133
* -Allow LOCALE to use indexes in regular expression searches(Tom)
B
Bruce Momjian 已提交
134
* -Allow array on int8[](Thomas)
B
Bruce Momjian 已提交
135
* Allow nulls in arrays
B
Bruce Momjian 已提交
136
* Allow arrays to be ORDER'ed
B
Bruce Momjian 已提交
137
* Remove Money type, add money formatting for decimal type
138
* Declare typein/out functions in pg_proc with a special "C string" data type
139
* Add non-large-object binary field
B
Bruce Momjian 已提交
140
* -Add index on NUMERIC/DECIMAL type(Jan)
B
Bruce Momjian 已提交
141
* -Make Absolutetime/Relativetime int4 because time_t can be int8 on some ports
B
Bruce Momjian 已提交
142
* Functions returning sets don't really work right[function]
B
Bruce Momjian 已提交
143
* Make type equivalency apply to aggregates(Peter E.)
B
Bruce Momjian 已提交
144 145

VIEWS
B
Bruce Momjian 已提交
146

B
Bruce Momjian 已提交
147
* Allow DISTINCT on views
B
Bruce Momjian 已提交
148
* Allow views of aggregate columns
B
Bruce Momjian 已提交
149 150
* Allow views with subselects

B
Bruce Momjian 已提交
151
INDEXES
B
Bruce Momjian 已提交
152 153

* Allow CREATE INDEX zman_index ON test (date_trunc( 'day', zman ) datetime_ops)
B
Bruce Momjian 已提交
154
  fails index can't store constant parameters
B
Bruce Momjian 已提交
155
* Allow creation of functional indexes to use default types
B
Bruce Momjian 已提交
156
* -Permissions on indexes, prevent them(Peter E)
B
Bruce Momjian 已提交
157 158
* Allow SQL function indexes
* Add FILLFACTOR to index creation
B
Bruce Momjian 已提交
159 160
* -Allow indexing of LIKE with localle character sets
* -Allow indexing of more than eight columns
B
Bruce Momjian 已提交
161 162

COMMANDS
B
Bruce Momjian 已提交
163

B
Bruce Momjian 已提交
164
* ALTER TABLE ADD COLUMN to inherited table put column in wrong place [inherit]
B
Bruce Momjian 已提交
165
* -Add ALTER TABLE DROP/ALTER COLUMN feature(Peter E)
B
Bruce Momjian 已提交
166
* Allow CLUSTER on all tables at once, and improve CLUSTER, loses NOT
B
Bruce Momjian 已提交
167
	NULL specification, indexes, permissions, etc on table[cluster]
B
Bruce Momjian 已提交
168
* Add SIMILAR TO to allow character classes, 'pg_[a-c]%'
B
Bruce Momjian 已提交
169
* Auto-destroy sequence on DROP of table with SERIAL(Ryan)
B
Bruce Momjian 已提交
170 171
* Allow LOCK TABLE tab1, tab2, tab3 so all tables locked in unison
* Allow INSERT/UPDATE of system-generated oid value for a row
B
Bruce Momjian 已提交
172
* Allow ESCAPE '\' at the end of LIKE for ANSI compliance [like]
B
Bruce Momjian 已提交
173
* Rewrite the LIKE handling by rewriting the user string with the 
B
Bruce Momjian 已提交
174
  supplied ESCAPE [like]
B
Bruce Momjian 已提交
175
* -Move LIKE index optimization handling to the optimizer(Tom)
B
Bruce Momjian 已提交
176
* Allow RULE recompilation
B
Bruce Momjian 已提交
177
* Support UNION/INTERSECT/EXCEPT in sub-selects
B
Bruce Momjian 已提交
178
* Allow DELETE and UPDATE to use inheritance using tablename*
B
Bruce Momjian 已提交
179
  
B
Bruce Momjian 已提交
180 181
CLIENTS

B
Bruce Momjian 已提交
182
* Make NULL's come out at the beginning or end depending on the 
B
Bruce Momjian 已提交
183
  ORDER BY direction
184
* -Allow flag to control COPY input/output of NULLs
B
Bruce Momjian 已提交
185
* Update reltuples from COPY command
B
Bruce Momjian 已提交
186
* -Allow psql \copy to allow delimiters
B
Bruce Momjian 已提交
187 188
* -Add a function to return the last inserted oid, for use in psql
	scripts (Peter E)
B
Bruce Momjian 已提交
189
* -Allow psql to print nulls as distinct from "" [null]
B
Bruce Momjian 已提交
190
* fix array handling for ECPG
B
Bruce Momjian 已提交
191
* add pg_dump option to dump type names as standard ANSI types
B
Bruce Momjian 已提交
192

193 194 195 196 197 198
EXOTIC FEATURES

* Add sql3 recursive unions
* Add the concept of dataspaces
* Add replication of distributed databases
* Allow queries across multiple databases
B
Bruce Momjian 已提交
199
* Allow nested transactions
200

B
Bruce Momjian 已提交
201 202
MISC

B
Bruce Momjian 已提交
203
* Increase identifier length(NAMEDATALEN) if small performance hit
B
Bruce Momjian 已提交
204 205 206
* Allow row re-use without vacuum(Vadim)
* Create a background process for each database that runs while
  database is idle, finding superceeded rows, gathering stats and vacuuming
B
Bruce Momjian 已提交
207
* Add UNIQUE capability to non-btree indexes
B
Bruce Momjian 已提交
208
* Certain indexes will not shrink, i.e. oid indexes with many inserts(Vadim)
B
Bruce Momjian 已提交
209 210
* Restore unused oid's on backend exit if no one else has gotten oids
* Have UPDATE/DELETE clean out indexes
B
Bruce Momjian 已提交
211
* -Allow WHERE restriction on ctid(Hiroshi)
B
Bruce Momjian 已提交
212
* Allow cursors to be DECLAREd/OPENed/CLOSEed outside transactions
B
Bruce Momjian 已提交
213
* Allow DELETE WHERE CURRENT OF cursor
B
Bruce Momjian 已提交
214
* -Allow PQrequestCancel() to terminate when in waiting-for-lock state
B
Bruce Momjian 已提交
215 216
* Transaction log, so re-do log can be on a separate disk by
  with after-row images(Vadim) [logging](Vadim)(in-progress)
B
Bruce Momjian 已提交
217 218
* Populate backend status area and write program to dump status data
* Make oid use unsigned int more reliably, pg_atoi()
B
Bruce Momjian 已提交
219
* -Allow subqueries in target list(Tom)
B
Bruce Momjian 已提交
220 221
* Put sort files, large objects in their own directory
* Do autocommit so always in a transaction block(?)
B
Bruce Momjian 已提交
222
* Show location of syntax error in query [yacc]
B
Bruce Momjian 已提交
223
* Redesign the function call interface to handle NULLs better[function](Tom)
B
Bruce Momjian 已提交
224 225
* -Document/trigger/rule so changes to pg_shadow recreate pg_pwd
  [pg_shadow](Peter E.)
B
Bruce Momjian 已提交
226
* Missing optimizer selectivities for date, r-tree, etc. [optimizer]
B
Bruce Momjian 已提交
227
* -Overhaul mdmgr/smgr to fix double unlinking and double opens, cleanup
B
Bruce Momjian 已提交
228
* Overhaul bufmgr/lockmgr/transaction manager
B
Bruce Momjian 已提交
229
* -Add PL/Perl(Mark Hollomon)
B
Bruce Momjian 已提交
230
* -Add option for postgres user have a password by default(Peter E)
B
Bruce Momjian 已提交
231
* Add configure test to check for C++ need for *.h and namespaces
232
* Allow BLCKSZ <= 64k, not <= 32k
B
Bruce Momjian 已提交
233
* redesign UNION structures to have separarate target lists
B
Bruce Momjian 已提交
234
* Allow multi-level query trees for INSERT INTO ... SELECT
B
Bruce Momjian 已提交
235 236 237

PERFORMANCE
-----------
B
Bruce Momjian 已提交
238 239 240

FSYNC

B
Bruce Momjian 已提交
241
* Allow transaction commits with rollback with no-fsync performance [fsync](Vadim)
B
Bruce Momjian 已提交
242
* -Prevent fsync in SELECT-only queries(Vadim)
B
Bruce Momjian 已提交
243

B
Bruce Momjian 已提交
244 245
INDEXES

B
Bruce Momjian 已提交
246
* Use indexes in ORDER BY for min(), max()
B
Bruce Momjian 已提交
247
* Use index to restrict rows returned by multi-key index when used with
B
Bruce Momjian 已提交
248
  non-consecutive keys or OR clauses, so fewer heap accesses
B
Bruce Momjian 已提交
249
* -Convert function(constant) into a constant for index use(Bernard Frankpitt)
B
Bruce Momjian 已提交
250 251
* Improve LIMIT processing by using index to limit rows processed [limit]
* Have optimizer take LIMIT into account when considering index scans [limit]
B
Bruce Momjian 已提交
252
* -Make index creation use psort code, because it is now faster(Tom)
B
Bruce Momjian 已提交
253
* -Allow creation of sort temp tables > 1 Gig
B
Bruce Momjian 已提交
254 255 256 257
* -Create more system table indexes for faster cache lookups
* -fix indexscan() so it does leak memory by not requiring caller to
free(Tom)
* -Improve _bt_binsrch() to handle equal keys better, remove _bt_firsteq()(Tom)
B
Bruce Momjian 已提交
258 259
* Allow SELECT * FROM tab WHERE int2col = 4 use int2col index, int8,
  float4, numeric/decimal too [optimizer]
B
Bruce Momjian 已提交
260
* -Allow optimizer to prefer plans that match ORDER BY(Tom)
B
Bruce Momjian 已提交
261
* Include heap CTID in btree index keys, remove equal-key cruft from btree
B
Bruce Momjian 已提交
262

B
Bruce Momjian 已提交
263 264
CACHE

B
Bruce Momjian 已提交
265
* Cache most recent query plan(s) [prepare]
B
Bruce Momjian 已提交
266
* Shared catalog cache, reduce lseek()'s by caching table size in shared area
B
Bruce Momjian 已提交
267
* -elog() flushes cache, try invalidating just entries from current xact,
B
Bruce Momjian 已提交
268 269
  perhaps using invalidation cache

B
Bruce Momjian 已提交
270

B
Bruce Momjian 已提交
271 272
MISC

B
Bruce Momjian 已提交
273
* Allow compression of log and meta data
B
Bruce Momjian 已提交
274
* Allow char() not to use variable-sized header to reduce disk size
B
Bruce Momjian 已提交
275
* Allow char1 data type that takes one byte of storage
B
Bruce Momjian 已提交
276
* Do async I/O to do better read-ahead of data
B
Bruce Momjian 已提交
277
* -Fix memory exhaustion when using many OR's [cnfify](Tom)
B
Bruce Momjian 已提交
278
* Get faster regex() code from Henry Spencer <henry@zoo.utoronto.ca>
B
Bruce Momjian 已提交
279
  when it is available
B
Bruce Momjian 已提交
280
* Use mmap() rather than SYSV shared memory(?)
B
Bruce Momjian 已提交
281
* -Process const = const parts of OR clause in separate pass(Bernard Frankpitt)
B
Bruce Momjian 已提交
282
* Make oid use oidin/oidout not int4in/int4out in pg_type.h
B
Bruce Momjian 已提交
283
* Improve Subplan list handling
B
Bruce Momjian 已提交
284
* Allow Subplans to use efficient joins(hash, merge) with upper variable
B
Bruce Momjian 已提交
285
  [subquery]
B
Bruce Momjian 已提交
286 287 288
* use fmgr_info()/fmgr_faddr() instead of fmgr() calls in high-traffic
  places, like GROUP BY, UNIQUE, index processing, etc.
* improve dynamic memory allocation by introducing tuple-context memory
B
Bruce Momjian 已提交
289
  allocation [memory]
B
Bruce Momjian 已提交
290
* -fix memory leak in cache code when non-existant table is referenced
B
Bruce Momjian 已提交
291
* In WHERE tab1.x=3 AND tab1.x=tab2.y, add tab2.y=3
B
Bruce Momjian 已提交
292
* -pass atttypmod through parser in more cases [atttypmod]
B
Bruce Momjian 已提交
293
* -remove duplicate type in/out functions for disk and net
B
Bruce Momjian 已提交
294
* Allow persistent backends [persistent]
B
Bruce Momjian 已提交
295
* others [performance]
296

B
Bruce Momjian 已提交
297 298
SOURCE CODE
-----------
B
Bruce Momjian 已提交
299
* Add use of 'const' for variables in source tree
B
Bruce Momjian 已提交
300
* Fix C optimizer problem where fmgr_ptr calls return different types [alpha]
B
Bruce Momjian 已提交
301
* -Add needed includes and removed unneeded include files(Bruce)
B
Bruce Momjian 已提交
302
* -Make configure --enable-debug add -g on compile line
B
Bruce Momjian 已提交
303
* Does Mariposa source contain any other bug fixes?
B
Bruce Momjian 已提交
304
* Remove SET KSQO option if OR processing is improved(Tom)
B
Bruce Momjian 已提交
305
* -Pre-generate lex and yacc output so not required for install
306

B
Bruce Momjian 已提交
307 308 309 310 311 312 313
---------------------------------------------------------------------------


Developers who have claimed items are:
--------------------------------------
	* Billy is Billy G. Allie <Bill.Allie@mug.org>
	* Brook is Brook Milligan <brook@trillium.NMSU.Edu>
B
Bruce Momjian 已提交
314
	* Bruce is Bruce Momjian<pgman@candle.pha.pa.us>
B
Bruce Momjian 已提交
315 316 317 318 319
	* Bryan is Bryan Henderson<bryanh@giraffe.netgate.net>
	* D'Arcy is D'Arcy J.M. Cain <darcy@druid.net>
	* David is David Hartwig <daveh@insightdist.com>
	* Edmund is Edmund Mergl <E.Mergl@bawue.de>
	* Goran is Goran Thyni <goran@kyla.kiruna.se>
B
Bruce Momjian 已提交
320
	* Hiroshi is Hiroshi Inoue<Inoue@tpf.co.jp>
B
Bruce Momjian 已提交
321 322 323 324 325 326
	* Jan is Jan Wieck <wieck@sapserv.debis.de>
 	* Marc is Marc Fournier <scrappy@hub.org>
	* Massimo Dal Zotto <dz@cs.unitn.it>
	* Michael is Michael Meskes <meskes@postgresql.org>
	* Oleg is Oleg Bartunov <oleg@sai.msu.su>
	* Peter is Peter T Mount <peter@retep.org.uk>
B
Bruce Momjian 已提交
327
	* Peter E is Peter Eisentraut<peter_e@gmx.net>
B
Bruce Momjian 已提交
328
	* Ryan is Ryan Bradetich <rbrad@hpb50023.boi.hp.com>
B
Bruce Momjian 已提交
329 330 331 332 333 334 335 336
	* Stefan Simkovics <ssimkovi@rainbow.studorg.tuwien.ac.at>
	* Tatsuo is Tatsuo Ishii <t-ishii@sra.co.jp>
	* Tom is Tom Lane <tgl@sss.pgh.pa.us>
	* Thomas is Thomas Lockhart <lockhart@alumni.caltech.edu>
	* TomH is Tom I Helbekkmo <tih@Hamartun.Priv.NO>
	* Vadim is "Vadim B. Mikheev" <vadim@krs.ru>