Re: insert only if conditions are met?

From: Ragnar Hafstað <gnari(at)simnet(dot)is>
To: Henry Ortega <juandelacruz(at)gmail(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: insert only if conditions are met?
Date: 2005-08-31 16:44:58
Message-ID: 1125506698.2605.22.camel@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Wed, 2005-08-31 at 11:49 -0400, Henry Ortega wrote:
> What I am trying to do is
> * Insert a record for EMPLOYEE A to TABLE A
> IF
> the sum of the hours worked by EMPLOYEE A on TABLE A
> is not equal to N
>
> Is this possible?

Sure, given a suitable schema

It is not clear to me, if the hours worked are
to be found in the same table you want to insert
into, or not.

gnari

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Henry Ortega 2005-08-31 16:49:14 Re: insert only if conditions are met?
Previous Message Chris Travers 2005-08-31 16:40:22 Re: insert only if conditions are met?