given the following sample table structure is there a way to add to a unique constraint to insure uniqueness for (GUID, 'Y') combination?
Application logic - update by guid
generates a new version with same guid
but new luid
; and previous goes inactive('Y'->'N')
GUID - external id
LUID - internal id
create table id_active(
"GUID" RAW(16) NOT NULL,
"LUID" RAW(16) NOT NULL,
"IS_ACTIVE" char(1) NOT NULL CHECK ( "IS_ACTIVE" IN ('Y', 'N')),
PRIMARY KEY ("GUID", "LUID"),
--unique constraint goes here