| From: | Ron Johnson <ronljohnsonjr(at)gmail(dot)com> |
|---|---|
| To: | pgsql-general <pgsql-general(at)postgresql(dot)org> |
| Subject: | Re: Lookup tables |
| Date: | 2025-02-04 14:56:26 |
| Message-ID: | CANzqJaD-qFaf_v1fhhs73kfBFuTqkH_qZk1UGEJh95Wz7uF0Ng@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgadmin-support pgsql-general |
On Tue, Feb 4, 2025 at 9:41 AM David G. Johnston <david(dot)g(dot)johnston(at)gmail(dot)com>
wrote:
> On Tuesday, February 4, 2025, Rich Shepard <rshepard(at)appl-ecosys(dot)com>
> wrote:
>
>> Should lookup tables have a numeric FK column as well as the description
>> column?
>>
>> If so, how should I add an FK to the two lookup tables in my database?
>>
>
> Most do (have a surrogate PK) since it removes cascading updates
>
How does a synthetic PK "remove cascading updates"? Doesn't the decision
on whether or not to cascade update depend on the ON UPDATE CASCADE clause
of the FK definition?
--
Death to <Redacted>, and butter sauce.
Don't boil me, I'm still alive.
<Redacted> lobster!
| From | Date | Subject | |
|---|---|---|---|
| Next Message | David G. Johnston | 2025-02-04 14:59:09 | Re: Lookup tables |
| Previous Message | Rich Shepard | 2025-02-04 14:47:48 | Re: Lookup tables |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | David G. Johnston | 2025-02-04 14:59:09 | Re: Lookup tables |
| Previous Message | Rich Shepard | 2025-02-04 14:47:48 | Re: Lookup tables |