On Thu, Nov 19, 2020 at 12:21 PM Sebastien FLAESCH <sf(at)4js(dot)com> wrote:
> Is this ok
subjective; I find it confusing.
> / legal
expect that the system will tell you if what you are doing is illegal.
> / without risk? (when multiple users insert rows at the same time?)
>
add a unique index and it will be risk free - and you will see whether the
rate of errors is acceptable for you.
Seems if you are going to allow direct inserts though you should test
multiple inserted rows at a time, not just single-row.
I'd suggest using the newer GENERATED ALWAYS feature and prohibiting direct
specification of values for the sequence-backed column.
David J.