Re: pg_dumpall and check constraints - Mailing list pgsql-general

From Philip Warner
Subject Re: pg_dumpall and check constraints
Date
Msg-id 3.0.5.32.20000630234742.00bbd900@mail.rhyme.com.au
Whole thread Raw
In response to Re: pg_dumpall and check constraints  (Guillaume Perréal <perreal@lyon.cemagref.fr>)
List pgsql-general
At 15:35 30/06/00 +0200, Guillaume Perréal wrote:

<excerpt><excerpt>>>>>

</excerpt></excerpt><excerpt><excerpt>1. add fieldname to the definition of station, then use

FOREIGN KEY ("fieldname", "type") references "information" (fieldName,
code),

</excerpt>Well, I don't think adding the same value to each row of
"station" is the better solution. But it's a solution.

</excerpt><<<<<<<<


I agree.



<excerpt><excerpt>>>></excerpt></excerpt><excerpt><excerpt>


FOREIGN KEY ( "type") references "station_fields" ( code),

</excerpt>I tried : it doesn't work. It seems that view rows don't have OID, which are used in foreign key. (I deduce
thatfrom the error messages I've got  when I tried).  

<excerpt>

</excerpt></excerpt><<<<<<<<


Sorry, I assumed if I could define it (under 7.0.2), then it would work. But, as you say, it dies when you do an
insert. 


The only other alternative is to create a real table instead of a view (ie. break 'information' into multiple tables).
Orjust do what you have been doing... 





----------------------------------------------------------------

Philip Warner                    |     __---_____

Albatross Consulting Pty. Ltd.   |----/       -  \

(A.C.N. 008 659 498)             |          /(@)   ______---_

Tel: (+61) 0500 83 82 81         |                 _________  \

Fax: (+61) 0500 83 82 82         |                 ___________ |

Http://www.rhyme.com.au          |                /           \|

                                 |    --________--

PGP key available upon request,  |  /

and from pgp5.ai.mit.edu:11371   |/

pgsql-general by date:

Previous
From: Thomas Lockhart
Date:
Subject: Re: Timezone template for to_char(timestamp, '...')?
Next
From: Jeffery Collins
Date:
Subject: Re: Large Tables(>1 Gb)