Re: [ADMIN] How to troubleshoot a halted postgres 8.3 ?

2009-10-21 Thread stefan
Hi Scott, > Remember, alter table statements require a full table lock. So if that > transaction (including your update statements) doesn't end somehow (commit, > rollback) then all other connections looking at that table will wait. > Look at the pg_stat_activity and pg_locks views. Thanks,

[ADMIN] Range-based clustering?

2009-10-21 Thread Hans Guijt
Hi, I have an application that gathers data in a table (who doesn't around here? ;-) ). The behaviour is roughly as follows: - on any single day, a lot of information is inserted. Inserts are more or less in order of increasing timestamp; there may be inserts for data as far back as an hour or t

Re: [ADMIN] can I get a bit more attribute out of \dt directive?

2009-10-21 Thread Harald Fuchs
In article , Scott Marlowe writes: > Do you mean when the table was modified (i.e. alter table add column) > or when the data in the table was changed? If it's when the table was > changed, the easiest way is to store that in the comment for the table > whenever you alter it. Highly interesting

Re: [ADMIN] How to troubleshoot a halted postgres 8.3 ?

2009-10-21 Thread Scott Mead
On Wed, Oct 21, 2009 at 3:05 AM, stefan wrote: > > > > Thanks, you were right, I added an additional commit which solved the > problem. The hint was that the pg_lock view contained a lock entry which > said granted "No". > > This raises though the question of isolation level, afaik postgres defau

Re: [ADMIN] can I get a bit more attribute out of \dt directive?

2009-10-21 Thread Tom Lane
Harald Fuchs writes: > Highly interesting. I put an "EXECUTE 'COMMENT ON TABLE ...'" into an > AFTER INSERT OR UPDATE OR DELETE trigger, and this indeed works. Does > anyone see a drawback in modifying a table comment very often? As long as pg_description gets vacuumed or autovacuumed often eno

[ADMIN] Is it possible to have psql ignore the line I am typing?

2009-10-21 Thread Tena Sakai
Hi everybody, Is it possible to have psql ignore the line I am typing? That is, similar to '#' with unix shell. What I would like is to document my interaction with psql. If an exclamation mark were a comment character, I may type something like: silver=# ! I need to find out if data tagged as

Re: [ADMIN] Is it possible to have psql ignore the line I am typing?

2009-10-21 Thread Joshua D. Drake
On Wed, 2009-10-21 at 17:39 -0700, Tena Sakai wrote: > Hi everybody, > > Is it possible to have psql ignore the line I am typing? > That is, similar to '#' with unix shell. What I would > like is to document my interaction with psql. If an > exclamation mark were a comment character, I may type

Re: [ADMIN] Is it possible to have psql ignore the line I am typing?

2009-10-21 Thread Rosser Schwarz
On Wed, Oct 21, 2009 at 6:39 PM, Tena Sakai wrote: > Hi everybody, > > Is it possible to have psql ignore the line I am typing? > That is, similar to '#' with unix shell. > I believe the standard "--" remainder of line SQL comment glyph will work, as should the C-style "/* ... */" block comment

Re: [ADMIN] Is it possible to have psql ignore the line I am typing?

2009-10-21 Thread Tena Sakai
Thank you Joshua! > I believe -- will do what you like; It sure does. Regards, Tena Sakai tsa...@gallo.ucsf.edu -Original Message- From: Joshua D. Drake [mailto:j...@commandprompt.com] Sent: Wed 10/21/2009 5:41 PM To: Tena Sakai Cc: pgsql-admin@postgresql.org Subject: Re: [ADMIN] Is it

Re: [ADMIN] Is it possible to have psql ignore the line I am typing?

2009-10-21 Thread Tena Sakai
Thank you, Rosser. It is interesting to note that -- and "/* ... */" have slightly different behavior. Former is much like # in shell or // in some programming languages, while the latter shows multi-line propensity. Regards, Tena Sakai tsa...@gallo.ucsf.edu -Original Message- From: Ro