Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
Neil Conway <[EMAIL PROTECTED]> writes: > [ replace lcons with lprepend ] BTW ... you may or may not consider this relevant, but "prepend" is not a word, it's only a hackish neologism. I can't find it at all in Random House, and the Oxford English Dictionary lists it only as a "v. rare" synonym f

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
Neil Conway <[EMAIL PROTECTED]> writes: > It just doesn't strike me that "construction" is a very useful way to > talk about what this operation is actually doing, and is asymmetric > with lappend() for no good reason. The operation is "prepending" an > element to an existing list, so why not gi

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Neil Conway
On 23-Mar-04, at 10:31 PM, Tom Lane wrote: How do you mean it's no longer the case? ListCell looks exactly like a cons cell to me. Sorry, thinko on my part. I meant to say that lcons() is a Lispy name, which suggests a Lispy implementation. This is no longer the case. While lcons() isn't that ba

Re: [HACKERS] subversion vs cvs

2004-03-23 Thread Sailesh Krishnamurthy
> "Marc" == Marc G Fournier <[EMAIL PROTECTED]> writes: Marc> On Tue, 23 Mar 2004, Sailesh Krishnamurthy wrote: >> Which brings me to another question .. has anybody considered >> using subversion instead of CVS ? Marc> Why? not that I'm for a chance from something that isn't

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Christopher Kings-Lynne
If you have one (implying that you don't have a system OID column) then "DROP COLUMN oid" will drop it, but "SET WITHOUT OIDS" will not. Okay with you? Sounds fair. Chris ---(end of broadcast)--- TIP 7: don't forget to increase your free space map

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Tom Lane
Christopher Kings-Lynne <[EMAIL PROTECTED]> writes: > What I meant is - does it handle dropping a non-system 'oid' column? > ie. A user column that just happens to be named 'oid'. If you have one (implying that you don't have a system OID column) then "DROP COLUMN oid" will drop it, but "SET WITH

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Christopher Kings-Lynne
Will it handle this case: usa=# create table testy (a int4) without oids; usa=# alter table testy add oid int4; No. This is DROP not ADD. What I meant is - does it handle dropping a non-system 'oid' column? ie. A user column that just happens to be named 'oid'. Chris -

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
Neil Conway <[EMAIL PROTECTED]> writes: > On 23-Mar-04, at 7:05 PM, Tom Lane wrote: >> No, lcons is one of the names that I think we should stick with on >> historical grounds. It's widely used in the backend and it has the >> right connotations for anyone who's ever used Lisp. > I think it has e

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Tom Lane
Christopher Kings-Lynne <[EMAIL PROTECTED]> writes: >> I am currently testing a fix that allows you to say >> ALTER TABLE DROP COLUMN oid; >> which will behave the same way a regular user-column DROP would. > Will it handle this case: > usa=# create table testy (a int4) without oids; > usa=# alter

Re: [HACKERS] dollar quoting and pg_dump

2004-03-23 Thread Tom Lane
Christopher Kings-Lynne <[EMAIL PROTECTED]> writes: > Does it _have_ to be dollars? Other languages call this feature > 'heretext' IIRC. I'm not in love with the name "dollar quoting" either ... but "here text" would be quite misleading. See the archives for the discussions that led us to devel

subversion vs cvs (Was: Re: [HACKERS] linked list rewrite)

2004-03-23 Thread Marc G. Fournier
On Tue, 23 Mar 2004, Sailesh Krishnamurthy wrote: > Which brings me to another question .. has anybody considered using > subversion instead of CVS ? Why? not that I'm for a chance from something that isn't broken, but what advantages does subversion give us over what we already have? Marc

[HACKERS] PANIC: hash table "Shared Buffer Lookup Table" corrupted

2004-03-23 Thread Jim Buttafuoco
All, Just started an upgrade from 7.2.X to 7.4.2. I am getting the following PANIC when loading the data from a 7.2.4 db using 7.4.2 pg_dump via a pipe pg_dump -h bda4c OLD_DB |psql -h bda5 -e NEW_DB bda4c isPostgreSQL 7.2.4 on i686-pc-linux-gnu, compiled by GCC 2.95.4 bda5 isPostgre

Re: [HACKERS] pg_dump locks a table on dumping ... ?

2004-03-23 Thread Marc G. Fournier
On Tue, 23 Mar 2004, Tom Lane wrote: > "Marc G. Fournier" <[EMAIL PROTECTED]> writes: > > 'k, just had someone tell me that they believed that a pg_dump will lock a > > table while the dump is happening ... my first thought/response was that > > this would defeat the point of MVCC, no? And would

Re: [HACKERS] dollar quoting and pg_dump

2004-03-23 Thread Jon Jensen
On Wed, 24 Mar 2004, Christopher Kings-Lynne wrote: > > I don't mind if it's on by default; just thinking that some people might > > appreciate a way to turn it off. "-X disable-dollar-quoting" sounds > > fine. > > Does it _have_ to be dollars? Other languages call this feature > 'heretext' II

Re: [HACKERS] dollar quoting and pg_dump

2004-03-23 Thread Andrew Dunstan
Christopher Kings-Lynne wrote: I don't mind if it's on by default; just thinking that some people might appreciate a way to turn it off. "-X disable-dollar-quoting" sounds fine. Does it _have_ to be dollars? Other languages call this feature 'heretext' IIRC. This is not heretext, and calli

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Bruce Momjian
Neil Conway wrote: > On 23-Mar-04, at 7:05 PM, Tom Lane wrote: > > No, lcons is one of the names that I think we should stick with on > > historical grounds. It's widely used in the backend and it has the > > right connotations for anyone who's ever used Lisp. > > I think it has exactly the *wron

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Christopher Kings-Lynne
I am currently testing a fix that allows you to say ALTER TABLE DROP COLUMN oid; which will behave the same way a regular user-column DROP would. I intend to interpret SET WITHOUT OIDS as DROP COLUMN oid RESTRICT. Will it handle this case: usa=# create table testy (a int4) without oids; CR

Re: [HACKERS] dollar quoting and pg_dump

2004-03-23 Thread Christopher Kings-Lynne
I don't mind if it's on by default; just thinking that some people might appreciate a way to turn it off. "-X disable-dollar-quoting" sounds fine. Does it _have_ to be dollars? Other languages call this feature 'heretext' IIRC. Chris ---(end of broadcast)---

Re: [HACKERS] Chapter on PostreSQL in a book

2004-03-23 Thread Christopher Kings-Lynne
I'm at a loss as to how much we should focus on these sections. Do we use what's in GBorg ? Do the hackers have any suggestions ? There are 33 DBA tools and 19 Design tools in GBorg .. are there any specific tools that are "recommended" ? Well, I think there are really just two major active free

[HACKERS] where can I get the HTML docs

2004-03-23 Thread Paul Tillotson
Can anyone show me where to download a zipped tarball of .html files of what exists at the following link? http://www.postgresql.org/docs/7.4/static/index.html Thanks. Paul ---(end of broadcast)--- TIP 2: you can get off all lists at once with th

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> lconsno change >> lconsi lcons_int >> lconso lcons_oid > Should these be lnew or something clearer than cons-truct? No, lcons is one of the names that I think we should stick with on histori

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Bruce Momjian
Tom Lane wrote: > lcons no change > lconsilcons_int > lconsolcons_oid > Should these be lnew or something clearer than cons-truct? -- Bruce Momjian| http://candle.pha.pa.us [EMAIL PROTECTED] | (610) 359-1001 +

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
I wrote: > Let's see ... fleshing out this idea a bit, here's a rundown of all the > symbols in pg_list.h and suggested new names: Sheesh ... I forgot that I intended to do s/list_/l/g on that. Doing so brings up one problem, which is that the old version of lremove() conflicts with the new namin

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > What does the 'n' stand for in ncons? I also felt that lcons > (construct) and nconc(concat) were too similarly named. I think nconc is a direct copy from the Lisp original; whatever its origins are, they're back in Lisp prehistory. I don't mind renami

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > Neil Conway wrote: > >> Tom objected to changing the names: > > > I agree a renaming of list functions is good. If we had kept the > > original Berkeley code as-is, we would have a lot fewer developers > > today. :-) Making drastic

Re: [HACKERS] [COMMITTERS] pgsql-server/ oc/src/sgml/ref/alter_table.sgml

2004-03-23 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > >> Upgrade ALTER TABLE DROP COLUMN so that it can drop an OID column, and > >> remove separate implementation of ALTER TABLE SET WITHOUT OIDS in favor > >> of doing a regular DROP. > > > Does removing SET WITHOUT OIDS cause compatibilit

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > Neil Conway wrote: >> Tom objected to changing the names: > I agree a renaming of list functions is good. If we had kept the > original Berkeley code as-is, we would have a lot fewer developers > today. :-) Making drastic cleanups is often worthwile.

Re: [HACKERS] [COMMITTERS] pgsql-server/ oc/src/sgml/ref/alter_table.sgml ...

2004-03-23 Thread Bruce Momjian
Tom Lane wrote: > CVSROOT: /cvsroot > Module name: pgsql-server > Changes by: [EMAIL PROTECTED] 04/03/23 15:35:17 > > Modified files: > doc/src/sgml/ref: alter_table.sgml > src/backend/bootstrap: bootparse.y > src/backend/catalog: heap.c > src/backend/comma

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > I assume you are doing away with the FastList hack too, aren't you? Yup, we'll get to revert that junk too. regards, tom lane ---(end of broadcast)--- TIP 3: if posting/reading th

[HACKERS] Nested transaction proposal - take N (N > 2)

2004-03-23 Thread Alvaro Herrera
Hackers, I'm (again) trying to get my hands dirty on the nested transaction thingie. Hopefully I will have a lot more commitment this time ... I'm currently looking at whatever is missing in the description below. If you see anything that isn't being considered please let me know. -- Alvaro He

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Alvaro Herrera
On Tue, Mar 23, 2004 at 05:00:14AM -0500, Neil Conway wrote: [...] > The basic idea is to ditch the Lisp-style linked list representation > (in which a "list" is merely a pointer to the head node), and adopt a > new List struct like so: I assume you are doing away with the FastList hack too, a

Re: [HACKERS] Two-phase commit

2004-03-23 Thread Alvaro Herrera
On Tue, Mar 23, 2004 at 06:10:35PM +0200, Heikki Linnakangas wrote: > I have again updated my two-phase commit patches. Only minor > modifications. > > I haven't received any comments and there hasn't been any discussion on > the implementation, I suppose that nobody has given it a try. :( I have

Re: [HACKERS] Two-phase commit

2004-03-23 Thread Bruce Momjian
Agreed. I would like to 2-phase commit in 7.5. --- Heikki Linnakangas wrote: > I have again updated my two-phase commit patches. Only minor > modifications. > > I haven't received any comments and there hasn't been any dis

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Tom Lane
Robert Treat <[EMAIL PROTECTED]> writes: > Point being that in the original case, I think the index on the oid column > should be dropped automagically, to follow similar behavior with normal > columns. I am currently testing a fix that allows you to say ALTER TABLE DROP COLUMN oid; whi

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Robert Treat
On Tuesday 23 March 2004 02:34, Christopher Kings-Lynne wrote: > >>Maybe it needs CASCADE/RESTRICT added? > > > > Seems like overkill, considering that this is a very marginal feature. > > I'm happy to decree that it works in whichever way is the easiest to > > implement. > > In that case, it seems

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > Seems it should behave just like dropping a column of a table that > already has an index on it: Yeah. In fact, I am now wondering why we invented SET WITHOUT OIDS at all, rather than making DROP COLUMN allow the target to be OID.

Re: [HACKERS] bug in 7.4 SET WITHOUT OIDs

2004-03-23 Thread Bruce Momjian
Christopher Kings-Lynne wrote: > >>Maybe it needs CASCADE/RESTRICT added? > > > > Seems like overkill, considering that this is a very marginal feature. > > I'm happy to decree that it works in whichever way is the easiest to > > implement. > > In that case, it seems to me that it has to be defau

Re: [HACKERS] Two-phase commit

2004-03-23 Thread Heikki Linnakangas
I have again updated my two-phase commit patches. Only minor modifications. I haven't received any comments and there hasn't been any discussion on the implementation, I suppose that nobody has given it a try. :( There is still some rough edges, but I think it's good enough as a first cut. I pers

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Dustin Sallings
On Mar 23, 2004, at 8:39, Sailesh Krishnamurthy wrote: Which brings me to another question .. has anybody considered using subversion instead of CVS ? My guess would be only people who haven't used arch. :) Seriously, though. Decentralized, disconnected revision control is a lot nicer to wor

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Frank Wiles
On Tue, 23 Mar 2004 08:39:21 -0800 Sailesh Krishnamurthy <[EMAIL PROTECTED]> wrote: > Which brings me to another question .. has anybody considered using > subversion instead of CVS ? I for one would love to see more Open Source projects like PostgreSQL move to using subversion instead of CV

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Tom Lane
Neil Conway <[EMAIL PROTECTED]> writes: > The known remaining issues that need to be addressed are: > (1) API naming I'll keep my mouth shut about this one until some other people have had a chance to weigh in... > (3) Apply the work to CVS, and update the rest of the tree for the new > API > T

[HACKERS] Chapter on PostreSQL in a book

2004-03-23 Thread Sailesh Krishnamurthy
Hackers Along with some other folks I am co-authoring a chapter on PostgreSQL in the next edition of "Database System Concepts" by Silberschatz, Korth and Sudarshan (http://db-book.com) This is in the form of a "case study" and will follow the pattern in Chapters 25,26 and 27 (Part 8 in the Tabl

Re: [HACKERS] pg_dump locks a table on dumping ... ?

2004-03-23 Thread Tom Lane
"Marc G. Fournier" <[EMAIL PROTECTED]> writes: > 'k, just had someone tell me that they believed that a pg_dump will lock a > table while the dump is happening ... my first thought/response was that > this would defeat the point of MVCC, no? And would make for a terrible > backup procedure on a ve

Re: [HACKERS] linked list rewrite

2004-03-23 Thread Sailesh Krishnamurthy
Re changing APIs or not. I agree with Tom that an incremental change is easier. More importantly, it is also easier to test your implementation. Even if everybody agrees that the API should be changed, IMO a better way would be to first use your implementation with the old API and go through som

Re: [HACKERS] dollar quoting and pg_dump

2004-03-23 Thread Tom Lane
Andrew Dunstan <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> A thought: maybe just put this logic into the regular >> appendStringLiteral routine, and trigger it when the string contains any >> quotes or backslashes; if it has none, you can just use quotes ... > I did think of fallback, but rej

Re: [HACKERS] postgres on windows page update

2004-03-23 Thread Robert Treat
Those pages are wiki based, so anyone can add content to them as they see fit. Robert Treat On Tue, 2004-03-23 at 09:54, Shachar Shemesh wrote: > Hi, > > I'm wondering who's doing the "PostgreSQL on Windows" page > (http://techdocs.postgresql.org/guides/Windows). I wanted to offer to > add the

Re: [HACKERS] postgres on windows page update

2004-03-23 Thread Matthew T. O'Connor
> I'm wondering who's doing the "PostgreSQL on Windows" page > (http://techdocs.postgresql.org/guides/Windows). I wanted to offer to > add the OleDB project to the "Connecting your Windows applications to > PostgreSQL " section. Would probably be g

Re: [HACKERS] dollar quoting and pg_dump

2004-03-23 Thread Tom Lane
Andrew Dunstan <[EMAIL PROTECTED]> writes: > ... using it in dumping function bodies and comments on all objects, > with a prefix argument of "function" and "comment" respectively. There > might be other places where we want to use dollar quoting, but this > would be a good start, ISTM. Do we r

[HACKERS] dollar quoting and pg_dump

2004-03-23 Thread Andrew Dunstan
I had a brief look at this today. Basically, I thought of adding a new routine to dumputils.c thus: void appendStringLiteralDQ(PQExpBuffer buf, const char *str, const char *dqprefix) and using it in dumping function bodies and comments on all objects, with a prefix argument of "function" an

[HACKERS] postgres on windows page update

2004-03-23 Thread Shachar Shemesh
Hi, I'm wondering who's doing the "PostgreSQL on Windows" page (http://techdocs.postgresql.org/guides/Windows). I wanted to offer to add the OleDB project to the "Connecting your Windows applications to PostgreSQL " section. Current status is "

Re: [HACKERS] pg_autovacuum

2004-03-23 Thread Matthew T. O'Connor
On Tuesday 23 March 2004 12:32 am, Josh Berkus wrote: > Matt, > > > What I'm thinking is that the VACUUM command could be modified to write > > down some data from the stats system at vacuum time. Once the VACUUM > > command writes this down for itself then pg_autovacuum just uses that > > number

[HACKERS] linked list rewrite

2004-03-23 Thread Neil Conway
I'd like to wrap up the linked list rewrite, and get the code into CVS reasonably soon. If you're unfamiliar with the motivations for redesigning the linked list code, check the archives for previous discussions, such as: http://www.mail-archive.com/[EMAIL PROTECTED]/msg02204.html htt

[HACKERS] LIKE ANY and the like?

2004-03-23 Thread Fabien COELHO
Dear hackers, a small inconsistency with the syntax of any/all as describe from the documentation. One can write: psql> SELECT 'foo' ~~ ANY (ARRAY['%a%','%o%']); although the following yields a syntax error, even if LIKE is an operator, thus it should be allowed. psql> SELECT 'foo' LIKE ANY (A