BUG: Error in GENXTAB When a Question Mark Is Encountered

Last reviewed: April 30, 1996
Article ID: Q117353
The information in this article applies to:
  • Microsoft FoxPro for Windows, versions 2.5, 2.5a, 2.5b, 2.6
  • Microsoft FoxPro for MS-DOS, versions 2.0, 2.5, 2.5a, 2.5b, 2.6
  • Microsoft FoxPro for Macintosh, versions 2.5b, 2.5c

SYMPTOMS

When you are creating a cross-tab table with the Relational Query by Example (RQBE) tool and there is a question mark ("?") in the field data that is going to become a field name, you will receive one of the following error messages, depending on whether the question mark is alone or has other alphanumeric characters with it.

If "?" is in a field by itself, the following error message occurs:

   Line No.: 399
   Program GENXTAB
   Error: Unrecognized Phrase/Keyword in command.
   Source: REPLACE (m.f2) WITH &f2 + m.f3

If your data is alphanumeric and contains a question mark (for example, "B?C" or "B?1"), the following error message will occur:

   Line No.: 339
   Program GENXTAB
   Error: Invalid or duplicate field name.
   Source: CREATE CURSOR (outfname) FROM ARRAY outarray

CAUSE

GENXTAB.PRG should have "?" listed as a "bad" character.

RESOLUTION

  1. Open GENXTAB.PRG in a editing window.

  2. From the Edit menu, choose Find.

  3. In the Look For box, type "badchars" (without the quotation marks).

  4. On the line that starts with "m.badchars =", type a ? inside the quotation marks after the equal sign.

  5. Save GENXTAB.PRG.

The next time you generate a cross-tab table, you will not get an error.

STATUS

Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

MORE INFORMATION

Steps to Reproduce Problem

NOTE: These steps reproduce only the first error listed above.

  1. Create a table with the following structure:

          Field name          Width         Type
          --------------------------------------
    
          FNAME                10             C
          GRADE                 3             C
    
    
    

  2. Put three records in the database:

          FNAME       GRADE
          -----------------
    
          Eric          A
          Eric          A
          Eric          ?
    
    

  3. Run a cross-tab with the third field being a COUNT() function on GRADE; that is, COUNT(GRADE).

  4. Choose the Do Query button.

The first error message listed above will appear.


Additional reference words: FoxDos FoxWin 2.00 2.50 2.50a 2.50b 2.50c 2.60
XTAB
errmsg
err msg crosstab cross tab cross tabulation cross tabular format
buglist2.00 buglist2.50 buglist2.50a buglist2.50b buglist2.50c buglist2.60
KBCategory: kbtool kbprg kberrmsg kbbuglist
KBSubcategory: FxtoolRqbe


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: April 30, 1996
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.