Re: [GENERAL] Perl interfaces?

2000-06-01 Thread Thomas Good
On Tue, 30 May 2000, Philip Hallstrom wrote: > Hi - > I took a look around and was unable to find a Perl DBI driver for > PostgreSQL... does one exist that I'm missing? If not, which of the three > drivers at cpan.org is the best (please no wars :) > -philip Phil, I use DBI and DBD-Pg.

Re: [GENERAL] query optimiser changes 6.5->7.0

2000-06-01 Thread Joseph Shraibman
Tom Lane wrote: > > Also, 7.0.1, propagating now to an archive near you, contains some > fudge-factor twiddling to make it more willing to choose an indexscan. > We shall soon find out whether that made things better or worse for > typical uses... > > regards, tom lane O

Re: [GENERAL] btree index and max()

2000-06-01 Thread Elliot Finley
On Thu, 1 Jun 2000 19:10:48 -0300, [EMAIL PROTECTED] wrote: >> [EMAIL PROTECTED] writes: >> > I understand that the query planner cannot be so clever >> > to grasp that this particular function (max or min) >> > might be evaluated by just travelling the BTREE index. >> > Am I correct? >> >

Re: [GENERAL] interval questions

2000-06-01 Thread Michael Blakeley
At 10:21 PM -0500 6/1/2000, Ed Loehr wrote: >Michael Blakeley wrote: >> >> CREATE TABLE EVENTS( stamp date, id varchar(16), event varchar(128) ); >> >> I'm trying to find the average age of the records. I've gotten as far as: >> SELECT DISTINCT ON(id) age(stamp) FROM EVENTS; >> >> Now,

Re: [GENERAL] interval questions

2000-06-01 Thread Ed Loehr
Michael Blakeley wrote: > > CREATE TABLE EVENTS( stamp date, id varchar(16), event varchar(128) ); > > I'm trying to find the average age of the records. I've gotten as far as: > SELECT DISTINCT ON(id) age(stamp) FROM EVENTS; > > Now, I need the DISTINCT ON(id), but that means I can't s

Re: [GENERAL] ALTERING A TABLE

2000-06-01 Thread Richard Smith
--snip-- Or is that CAST it on the wasy. Richard

Re: [GENERAL] interval questions

2000-06-01 Thread Alfred Perlstein
* Michael Blakeley <[EMAIL PROTECTED]> [000601 19:09] wrote: > I hope someone on the list can suggest a solution for me - given a table like > > CREATE TABLE EVENTS( stamp date, id varchar(16), event varchar(128) ); > > I'm trying to find the average age of the records. I've gotten as far as: >

Re: [GENERAL] interval questions

2000-06-01 Thread Tom Lane
Michael Blakeley <[EMAIL PROTECTED]> writes: > I'm trying to find the average age of the records. I've gotten as far as: > SELECT DISTINCT ON(id) age(stamp) FROM EVENTS; > Now, I need the DISTINCT ON(id), but that means I can't simply avg() the age: > ERROR: Attribute events.id must

Re: [GENERAL] query optimiser changes 6.5->7.0

2000-06-01 Thread Tom Lane
"Simon Hardingham" <[EMAIL PROTECTED]> writes: > I have run explain on the query and it shows that it is just > performed a sequential scan on version 7.0 > Seq Scan on gazet (cost.) > On the old version (6.5.1) it reports > Index Scan using gazet_index on gazet (cost= > Any suggesti

[GENERAL] interval questions

2000-06-01 Thread Michael Blakeley
I hope someone on the list can suggest a solution for me - given a table like CREATE TABLE EVENTS( stamp date, id varchar(16), event varchar(128) ); I'm trying to find the average age of the records. I've gotten as far as: SELECT DISTINCT ON(id) age(stamp) FROM EVENTS; Now, I need the D

Re: [GENERAL] PostgreSQL article in LinuxWorld

2000-06-01 Thread Ron Chmara
Bruce Momjian wrote: > > > On Wed, May 31, 2000 at 04:27:24PM -0400, Bruce Momjian wrote: > > > http://www.linuxworld.com/linuxworld/lw-2000-05/lw-05-database.html > > > > > > It mentions PostgreSQL. I was interviewed for the article. > > > > Nice article, but the author should get some facs

[GENERAL] make install for docs in 7.0.1 won't work.

2000-06-01 Thread Joseph Shraibman
I did a make install in doc in the 7.0 release, but now when I try it: make all make[1]: Entering directory `/tmp/postgresql-7.0.1/doc' make[1]: *** No rule to make target `admin', needed by `all'. Stop. make[1]: Leaving directory `/tmp/postgresql-7.0.1/doc' make: *** [install] Error 2

Re: [GENERAL] PostgreSQL article in LinuxWorld

2000-06-01 Thread Bruce Momjian
> On Wed, May 31, 2000 at 04:27:24PM -0400, Bruce Momjian wrote: > > http://www.linuxworld.com/linuxworld/lw-2000-05/lw-05-database.html > > > > It mentions PostgreSQL. I was interviewed for the article. > > Nice article, but the author should get some facst straight. Postgres was > never s

Re: [GENERAL] Postmaster won't -HUP

2000-06-01 Thread Tom Lane
Jerry Lynde <[EMAIL PROTECTED]> writes: > Thanks for the tip. I might indeed take that approach in the future, > however that's not really the problem I'm trying to tackle right now. > Indexing by Last Name is fine with me, currently. What's not working for me > is the part where the dual

Re: [GENERAL] Q: Truncated output

2000-06-01 Thread Ross J. Reedstrom
On Thu, Jun 01, 2000 at 08:51:13PM +, Elliot Finley wrote: > I've just started using Postgres 6.5.2 and I'm trying to figure out a > way to be able to see the complete 'type' for the 'employee_id' field. > I can't remember which sequence I used in the 'nextval', so I need to > be able to see w

Re: [GENERAL] btree index and max()

2000-06-01 Thread leonbloy
> [EMAIL PROTECTED] writes: > > I understand that the query planner cannot be so clever > > to grasp that this particular function (max or min) > > might be evaluated by just travelling the BTREE index. > > Am I correct? > > You are correct --- the system has no idea that there is any > c

Re: [GENERAL] PostgreSQL article in LinuxWorld

2000-06-01 Thread Michael Meskes
On Wed, May 31, 2000 at 04:27:24PM -0400, Bruce Momjian wrote: > http://www.linuxworld.com/linuxworld/lw-2000-05/lw-05-database.html > > It mentions PostgreSQL. I was interviewed for the article. Nice article, but the author should get some facst straight. Postgres was never sold as Ingre

Re: [GENERAL] index problem

2000-06-01 Thread Tom Lane
Marcin Inkielman <[EMAIL PROTECTED]> writes: > I created an index using pgaccess rescently. the name of the index was > long: > "oceny_stud_numer_albumu_protokoloceny_stud" > now i am unable to vacuum my database. Oh dear :-( ... it seems that when you quote an identifier, the system forgets to m

Re: [GENERAL] Postmaster won't -HUP

2000-06-01 Thread Jerry Lynde
At 05:58 PM 6/1/00 -0400, you wrote: Jerry Lynde <[EMAIL PROTECTED]> writes: They are all indexed, the DOB index is actually DOBYear DOBDay and DOBMonth and all 5 fields are indexed >> >> Do you have 5 indexes or do you have an index that spans more than one >> field? > Sorry for

Re: [GENERAL] Postmaster won't -HUP

2000-06-01 Thread Tom Lane
Jerry Lynde <[EMAIL PROTECTED]> writes: They are all indexed, the DOB index is actually DOBYear DOBDay and DOBMonth and all 5 fields are indexed >> >> Do you have 5 indexes or do you have an index that spans more than one >> field? > Sorry for being less than explicit. There are 5 sep

Re: [GENERAL] btree index and max()

2000-06-01 Thread Tom Lane
[EMAIL PROTECTED] writes: > I understand that the query planner cannot be so clever > to grasp that this particular function (max or min) > might be evaluated by just travelling the BTREE index. > Am I correct? You are correct --- the system has no idea that there is any connection between the MI

Re: [GENERAL] Postmaster won't -HUP

2000-06-01 Thread Jerry Lynde
At 05:19 PM 6/1/00 -0400, Joseph Shraibman wrote: >Jerry Lynde wrote: > > > > At 12:11 PM 6/1/00 -0500, Ed Loehr wrote: > > >Jerry Lynde wrote: > > > > > > > > As for the query I'm running, it was simply select * from > > > bigtable (about > > > > 2-300k lines) where > > > >

Re: [GENERAL] Postmaster won't -HUP

2000-06-01 Thread Joseph Shraibman
Jerry Lynde wrote: > > At 12:11 PM 6/1/00 -0500, Ed Loehr wrote: > >Jerry Lynde wrote: > > > > > > As for the query I'm running, it was simply select * from > > bigtable (about > > > 2-300k lines) where > > > firstname= > fname> and > > >

Re: [GENERAL] Q: Truncated output

2000-06-01 Thread leonbloy
A quick and dirty trick, is to make a dump of the schema of the database (or the table): postgres# pg_dump -s [-t employee] > db.dump.schema Regards Hernan Gonzalez Buenos Aires, Argentina > I've just started using Postgres 6.5.2 and I'm trying to figure out a > way to be able to see the

[GENERAL] Q: Truncated output

2000-06-01 Thread Elliot Finley
I've just started using Postgres 6.5.2 and I'm trying to figure out a way to be able to see the complete 'type' for the 'employee_id' field. I can't remember which sequence I used in the 'nextval', so I need to be able to see which one is being used there. shift=> \d employee Table= employee

Re: [GENERAL] shared memory

2000-06-01 Thread Bruce Momjian
OK, John, I think I have an answer for you. It is not pretty. You actually got pretty close. First, increase SHMMAXPGS by 1024 for every additional 4MB of shared memory: /sys/sys/shm.h:69:#define SHMMAXPGS 1024/* max hardware pages... The default setting of 1024 is for a maxim

Re: [GENERAL] Postmaster won't -HUP

2000-06-01 Thread Jerry Lynde
At 01:21 PM 6/1/00 -0400, Tom Lane wrote: >Ed Loehr <[EMAIL PROTECTED]> writes: > > Jerry Lynde wrote: > >> > >> As for the query I'm running, it was simply select * from bigtable (about > >> 2-300k lines) where > >> firstname= and > >> lastname= and > >> DOB= > > > What indices do you have on th

Re: [GENERAL] Postmaster won't -HUP

2000-06-01 Thread Jerry Lynde
At 12:11 PM 6/1/00 -0500, Ed Loehr wrote: >Jerry Lynde wrote: > > > > As for the query I'm running, it was simply select * from > bigtable (about > > 2-300k lines) where > > firstname= fname> and > >

[GENERAL] index problem

2000-06-01 Thread Marcin Inkielman
hi! I created an index using pgaccess rescently. the name of the index was long: "oceny_stud_numer_albumu_protokoloceny_stud" now i am unable to vacuum my database. i obtain something like this when i try: NOTICE: Pages 310: Changed 0, reaped 2, Empty 0, New 0; Tup 48611: Vac 3, Keep/VTL 0/