Subject Re: [IBO] DML Caching
Author mkl20uk@yahoo.co.uk
--- In IBObjects@y..., Svein Erling Tysvær
<svein.erling.tysvaer@k...> wrote:
> >I think that is what I am doing. The two fields are a compound
primary key
> >and are:
> >
> >PCAT_UNIQUE_REF
> >PCAT_SYSTEM_REF
>
> A compound key where one of the elements is populated by a
generator? I
> suppose it ought to work, but it is a rather unusual situation.
Does it
> work any better if you reduce your PK to just PCAT_UNIQUE_REF (the
> generator should assure its uniqueness)?
>
> Set

I haven't tried but I would be loathe to drop the primary key to just
PCAT_UNIQUE_REF. The application supports replication and the
benefit of PCAT_SYSTEM_REF as part of the primary key is integrity
within both the application and any external processes that write to
the database (replication, SQL etc etc). I thought that this was
probably the safest way to handle the integrity. In all other
respects using a compound key in this way seems to work just fine,
the application is sold and, as far as I can tell, pretty quick.

Martin