PRB: No Syntax Error on SELECT Statement Using SYS(3)

ID: Q95723

The information in this article applies to:

SYMPTOMS

In FoxPro version 2.0 for MS-DOS, the following syntax example does not return an error message:

   SELECT * FROM customer INTO CURSOR SYS(3)

SYS(3) assigns a numeric alias name (12345678). However, in FoxPro for MS-DOS and Windows versions 2.5 and later, the SYS(3) parameter returns "Syntax error" because a cursor cannot have a numeric name.

RESOLUTION

To use the SYS(3) function with the SELECT statement in FoxPro version 2.5 and later, use the following syntax:

   SELECT * FROM customer INTO CURSOR "a" + SYS(3)

The "a" will prefix the alias of the query (a1234567).

STATUS

This behavior is by design.

Additional reference words: FoxDos FoxWin 2.50 2.50a unique filename errmsg err msg 2.50b 2.60 2.60a novel KBCategory: kbprg kberrmsg kbprb KBSubcategory: FxsetupError

Last Reviewed: June 26, 1995