Re: Lookup tables

From: Thiemo Kellner <thiemo(at)gelassene-pferde(dot)biz>
To: "pgsql-generallists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: Lookup tables
Date: 2025-02-07 11:07:56
Message-ID: dcb2ac8c-0931-4707-b573-f36aa345e70a@gelassene-pferde.biz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support pgsql-general

06.02.2025 22:04:34 Peter J. Holzer <hjp-pgsql(at)hjp(dot)at>:

>> I might see what you want to point out. E.g. the table is COLOURS. The
>> rec with id 1 is RED, the one with id 2 is BLUE, 3 is GREE and so on.
>> Now you load these values into the dropdown box that sports RED, BLUE,
>> GREE and so on. While someone selects GREE, there is a maintenance
>> release changing GREE to YELLOW. So when that someone sends the
>> selection by id to the backend, not GREE is selected but YELLOW.
>
> I fail to see why use of a surrogate key is the problem here.

It seems I did not make mys of clear. I don't see either and don' remember an occasion in over 20 years of DWH business the use of surrogates was a problem.

> Either changing the color from GREE to YELLOW makes sense or it doesn't.

Hear, hear.

> If it doesn't make sense, then it's release which is faulty, not the
> model.

ACK

Thiemo

In response to

Browse pgsql-general by date

  From Date Subject
Next Message ravi k 2025-02-07 13:00:10 Re: Commit Latency
Previous Message Andrey Borodin 2025-02-07 10:40:44 Re: Using Expanded Objects other than Arrays from plpgsql

Browse pgadmin-support by date

  From Date Subject
Previous Message Michał Kłeczek 2025-02-07 08:22:13 Re: Lookup tables