Deleted records in table with candidate key

Deleted records in table with candidate key

Post by Andrew Ducke » Thu, 27 Aug 1998 04:00:00




>Anyone have any good techniques for handling inserts into a table that has
a
>candidate key?

>The problem is that if a record has been deleted (but the table has not
been
>packed) a subsequent insert with the same key value will fail with
"Uniqueness
>violated" as VFP enforces the candidate key's uniqueness with deleted
records
>as well.

Do a search for the existence fo the key.  If it exists, do a replace rather
than an insert.

Next!

Andy D

 
 
 

Deleted records in table with candidate key

Post by Chuck Trip » Thu, 27 Aug 1998 04:00:00


Quote:> Do a search for the existence fo the key.  If it exists, do a replace rather
> than an insert.

> Next!

Then:
RECALL
SCATTER BLANK (MEMO if any)

??????

Chuck