BUG: ALTER TABLE Cannot Create a Descending Primary Key

ID: Q186242


The information in this article applies to:
  • Microsoft Visual FoxPro for Windows, versions 3.0b, 5.0, 5.0a, 6.0
  • Microsoft Visual FoxPro for Macintosh, version 3.0b


SYMPTOMS

The ALTER TABLE command cannot create a descending primary key index.


RESOLUTION

Use the Visual FoxPro interface to visually create a primary descending index key.


STATUS

Microsoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article.


MORE INFORMATION

Steps to Reproduce Behavior

  1. Create a program that contains the following code and run the program:
    
          USE home()+"samples\data\customer"
          MODIFY  STRUCTURE
          INDEX ON cust_id TAG cust_id DESCENDING
          MODIFY STRUCTURE
          ALTER TABLE customer ADD PRIMARY KEY cust_id TAG cust_id
          MODIFY  STRUCTURE 


  2. When the first Table Designer window appears, click the Indexes tab and note both the Order and Type for the Cust_id tag. The Indexes tab name is Index in Visual FoxPro 3.0. Click OK.


  3. Overwrite the Cust_id key when the warning message appears. Click the Indexes tab on the Table Designer window, noting that the Cust_id key is now a regular index type in descending order. Click OK.


  4. Overwrite the Cust_id key again when prompted. Click the Indexes tab of the Table Designer window. The Cust_id key is now a primary index key, but it is in ascending order.


Additional query words: kbDSupport KBDSE kbVFp500 kbVFp300bug kbVFp500abug kbVFp300b kbvfp600

Keywords :
Version : MACINTOSH:3.0b; WINDOWS:3.0b,5.0,5.0a,6.0
Platform : MACINTOSH WINDOWS
Issue type : kbbug


Last Reviewed: December 10, 1999
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.