Microsoft KB Archive/190318

= PRB: BINTOC Fails with SET COLLATE TO "GENERAL" =

Article ID: 190318

Article Last Modified on 4/17/2001

-

APPLIES TO


 * Microsoft Visual FoxPro 5.0 Standard Edition
 * Microsoft Visual FoxPro 5.0a
 * Microsoft Visual FoxPro 6.0 Professional Edition

-



This article was previously published under Q190318



SYMPTOMS
When creating an index using the BINTOC function, with the COLLATE set to GENERAL, the following error occurs:

Uniqueness of index is violated.



RESOLUTION
When you create an index using BINTOC, use "SET COLLATE TO MACHINE". In addition, when you create an index based on a NOCPTRANS field (binary character field), use "SET COLLATE TO MACHINE" or the same problem described earlier occurs.



STATUS
This behavior is by design.



Steps to Reproduce Behavior
Run the following sample code: CREATE TABLE test (id I, other I)  FOR lni = 1 TO 10 INSERT INTO test (id ) VALUE (lni) ENDFOR SET COLLATE TO "" INDEX ON BINTOC(id) TAG id CANDIDATE && Index successful. SET COLLATE TO "GENERAL" INDEX ON BINTOC(id) TAG idG CANDIDATE && Index fails. The last line of code fails with the error message described previously.

Additional query words: kbvfp600

Keywords: kbprb KB190318

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.