On Monday 01 March 2004 22:59, Curt Sampson wrote:
On Mon, 1 Mar 2004, Tom Lane wrote:
Curt Sampson [EMAIL PROTECTED] writes:
Can you explain how to do this? There is no reference to a plan in the
contract table; the constraint just checks to see that, if a contract
exists, there is at
On Tue, Mar 02, 2004 at 09:45:03 -0500,
Robert Treat [EMAIL PROTECTED] wrote:
Wouldn't a FK on both tables be the appropriate schema? With the FK on
contract being deffered?
No, since he only cares that there is at least one plan for a contract,
not a particular plan. You can do something
On Tue, 2 Mar 2004, Robert Treat wrote:
Wouldn't a FK on both tables be the appropriate schema? With the FK on
contract being deffered?
Unfortunately, it appears that an FK must reference a unique column. So this:
ALTER TABLE contract ADD CONSTRAINT contract_must_have_a_plan
On Thu, 26 Feb 2004, Tom Lane wrote:
Jonathan Scott [EMAIL PROTECTED] writes:
The functions and tables create just fine, but when it gets to the
COPY part of the sql script, it tries to load tables in what really is
the wrong order. The check constraint is making sure there is a plan
Curt Sampson [EMAIL PROTECTED] writes:
Can you explain how to do this? There is no reference to a plan in the
contract table; the constraint just checks to see that, if a contract
exists, there is at least one plan referencing that contract.
There is of course a foreign key constraint used in
On Mon, 1 Mar 2004, Tom Lane wrote:
Curt Sampson [EMAIL PROTECTED] writes:
Can you explain how to do this? There is no reference to a plan in the
contract table; the constraint just checks to see that, if a contract
exists, there is at least one plan referencing that contract.
There is
Tom,
I have another instance of a possible function being used as a check constraint: a
function that makes sure there is one row, and only one row in a table.
At table creation, and the creation of the constraint, there are no rows in the table.
So, even if the constraint is a valid one to
Jonathan Scott [EMAIL PROTECTED] writes:
The functions and tables create just fine, but when it gets to the
COPY part of the sql script, it tries to load tables in what really is
the wrong order. The check constraint is making sure there is a plan
before there is a contract, yet pg_dump is
Hello again,
A project I am working on has been having problems with pg_dump's output, using 7.3.
Our project's database includes functions that do constraint checking for us, as well
as circular dependencies.
We heard about the changes on the pgsql HEAD/7.5, and have given it a try. It fixed
Christopher Kings-Lynne [EMAIL PROTECTED] writes:
Why would there be any speed advantage?
Is it not faster to add it when all the data is there, rather than
evaluating it as each row is inserted, like indexes?
I don't see why. There are good algorithmic reasons why bulk-loading
an index is
Hi guys,
I notice that we're still dumping CHECK constraints as part of the CREATE
TABLE statement, and not as an ALTER TABLE statement after the data has been
loaded.
Should we move it to after the data for speed purposes, like we have with
all other constraints?
Chris
Christopher Kings-Lynne [EMAIL PROTECTED] writes:
I notice that we're still dumping CHECK constraints as part of the
CREATE
TABLE statement, and not as an ALTER TABLE statement after the data has
been
loaded.
Should we move it to after the data for speed purposes, like we have
with
12 matches
Mail list logo