[GENERAL] LibPQ Notice

1998-08-12 Thread Dirk Elmendorf
I have a program which opens two connections to two different databases. After issuing a few commands to the second database I this get in the trace log: To backend> QSELECT oid FROM order_table WHERE customer_number=936 ; >From backend> N >From backend> "NOTICE: SIMarkEntryData: cache state res

[GENERAL] designating a column as primary key after creation

1998-08-12 Thread Fran Fabrizio
Why does postgres choke on the following: alter table mytable add constraint mycolumn_pk primary key(mycolumn); is this possible in a postgres database? if not, what's an easy workaround, i really need to have this column as primary key. Thanks! -Fran

Re: [GENERAL] Select MIN() & MAX()

1998-08-12 Thread Jeremiah Davis
I'm using this in a an application right now: $result = pg_Exec($conn, "SELECT MAX(pos) FROM demogallery;"); and its been working fine for about 2-3 months... On Wed, 12 Aug 1998, Krasnow, Greg wrote: > In the documentation it mentions that Postgresql does not currently support > MIN() and M

Re: [GENERAL] Select MIN() & MAX()

1998-08-12 Thread Bruce Momjian
> In the documentation it mentions that Postgresql does not currently support > MIN() and MAX() in the select list, but only in the where clause... will > this be available in the next version of Postgresql and is there another way > to do this in the current version? But we do support them in th

Re: [GENERAL] Select MIN() & MAX()

1998-08-12 Thread Bruce Momjian
> oops... my goof... I read it too quickly... > > ok... one more stupid question... can you not do an "insert into t1 (select > 'a','b',min(f)-1 from t2)"? Do: insert into t1 select 'a','b',min(f)-1 from t2 I think that should work. -- Bruce Momjian | 830 Blythe Av

Re: [GENERAL] Select MIN() & MAX()

1998-08-12 Thread Dimitri
On Wed, 12 Aug 1998, you wrote: >oops... my goof... I read it too quickly... > >ok... one more stupid question... can you not do an "insert into t1 (select >'a','b',min(f)-1 from t2)"? Of course: insert into t1 select 'a', 'b', min(f) - 1 from t2; it's standard SQL > >- Greg > >G

[GENERAL] Unique key with nulls and copying databases across computers

1998-08-12 Thread Wim Ceulemans
Hi I have a few questions: 1. Is there a simple way in postgresql 6.3.2 to implement a unique index on one field with null's allowed. So if the field is null it's ok else the value must be unique? 2. I have copied the contents of a database ( ../data/base/name/* ) from one computer to another c

[GENERAL] Select MIN() & MAX()

1998-08-12 Thread Krasnow, Greg
oops... my goof... I read it too quickly... ok... one more stupid question... can you not do an "insert into t1 (select 'a','b',min(f)-1 from t2)"? - Greg Greg Krasnow HNC Software Inc. Financial Solutions Group Senior Software Engineer Email: [EMAIL PROTECTED] Direct Phone: 619.799.8341 Fax: 6

Re: [GENERAL] Select MIN() & MAX()

1998-08-12 Thread Dimitri
On Wed, 12 Aug 1998, you wrote: >In the documentation it mentions that Postgresql does not currently support >MIN() and MAX() in the select list, but only in the where clause... will >this be available in the next version of Postgresql and is there another way >to do this in the current version

[GENERAL] Select MIN() & MAX()

1998-08-12 Thread Krasnow, Greg
In the documentation it mentions that Postgresql does not currently support MIN() and MAX() in the select list, but only in the where clause... will this be available in the next version of Postgresql and is there another way to do this in the current version? - Greg Greg Krasnow HNC Software I

Re: [GENERAL] clean database

1998-08-12 Thread James Oden
-Original Message- From: Jeong Jae Ick:Á¤ÀçÀÍ: <[EMAIL PROTECTED]> To: Ryan Mchale <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Date: Wednesday, August 12, 1998 03:36 Subject: Re: [GENERAL] clean database >On 11 Aug 1998, Ryan Mchale wrote: > >> Hi, >> >> What's the clean command calle