Duplicate key inserted with dBase Unique index 
Author Message
 Duplicate key inserted with dBase Unique index

BDE delphi 2.0 problem.

I use a dBase table with a unique index on a string field.
But the insert method adds record with the same key value as an
existing one, without sending an error message.

How can I do to avoid this problem.

Thanks for Help

--

* I.N.S.A. Departement Informatique     L3I                         *
* Bat. 502 20, avenue Albert Einstein   Phone : (33) 72 43 83 75    *
* F-69621 VILLEURBANNE CEDEX  FRANCE    Fax   : (33) 72 43 85 18    *



Fri, 25 Dec 1998 03:00:00 GMT  
 Duplicate key inserted with dBase Unique index

Quote:
>BDE Delphi 2.0 problem.
>I use a dBase table with a unique index on a string field.
>But the insert method adds record with the same key value as an
>existing one, without sending an error message.
>How can I do to avoid this problem.

Don't use dBase tables.  

This is not a problem with the BDE.  It is as designed.  Ashton-Tate
in their infinite wisdom deemed that a unique index on dBase tables
does not affect what data can be stored, but will, when ordered by
that index, not show duplicates of that value.  Think of dBase unique
indexes as the same as doing a 'select distinct'.

Wade



Fri, 01 Jan 1999 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. dBase Unique indexes: No failure on duplicate insert

2. How to check Unique Key in Insert ?

3. Duplicate Key in DBase

4. Primary Key, Unique Index and Grid component

5. DBase Unique Index

6. unique index in dBase

7. dBase "Unique" Index Problem

8. DBASE Unique Index

9. DBase Table - unique Index

10. Preventing Key Violation for duplicate keys

11. Reuse of a deleted key value in a dBase index

12. Unique table inserts---need help...

 

 
Powered by phpBB® Forum Software