| From: | Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> |
|---|---|
| To: | stan <stanb(at)panix(dot)com>, pgsql-general(at)lists(dot)postgresql(dot)org |
| Subject: | Re: Input validation |
| Date: | 2019-08-07 18:18:17 |
| Message-ID: | 6ab6f7dd-4041-20c5-66d3-e530aee5a085@aklaver.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
On 8/7/19 11:07 AM, stan wrote:
> Have table that contains employee keys, paired up with work type keys
> (both foreign keys) and a 3rd column that you enter a billing rate in.
> Then I have a table where employees enter their work. I need to validate
> that the employee, work type pair exists, before allowing the new record
> to be inserted.
>
> Any thoughts as to good way to do this?
INSERT UPDATE trigger:
https://www.postgresql.org/docs/11/sql-createtrigger.html
https://www.postgresql.org/docs/11/plpgsql-trigger.html
>
>
--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Rob Sargent | 2019-08-07 18:21:44 | Re: Input validation |
| Previous Message | stan | 2019-08-07 18:07:17 | Input validation |