Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
(Error 1815) cursor must be created with SELECT INTO TAB
Message
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00187655
Message ID:
00187671
Views:
29
>James,
>
>When you do a simple query (no joins, no calculated fields) VFP sometimes just does a USE AGAIN on the table you select from and sets a filter on it. In this case you cannot do a SELECT from the resulting cursor because SELECT ignores any filter.
>
>If you're using VFP 5 or higher, use the NOFILTER keyword like this:
>
>SELECT * ;
>  FROM mytable ;
>  WHERE ... ;
>  INTO CURSOR mycursor NOFILTER
If you're using VFP 3.0 or earlier, just create a dummy calculated field:
>
>SELECT *, ' ' AS Dummy ;
>  FROM mytable ;
>  WHERE ... ;
>  INTO CURSOR mycursor
Either method will force VFP to create a new temporary dbf to hold the cursor instead of just filtering the original table.
>

An alternative in VFP 3 would be to add something simple to the WHERE clause that isn't Rushmore optimizable; I've found that adding AND .T. to the WHERE clause accomplished the same thing as adding the calculated field, without changing the structure of the resulting cursor.

>>Anyone know what this means: (Error 1815) cursor must be created with SELECT INTO TABLE?
>>
>>I am attempting to select from a cursor into a second cursor as the datasource for a report.
>>
>>Until today it worked. Now I get this strange error message.
>>
>>Evidently Select is not finding the source cursor -- even though it is the table returned by ALIAS() at the point where the second select commences.
>>
>>Any ideas would be appreciated.
>>
>>Regards,
EMail: EdR@edrauh.com
"See, the sun is going down..."
"No, the horizon is moving up!"
- Firesign Theater


NT and Win2K FAQ .. cWashington WSH/ADSI/WMI site
MS WSH site ........... WSH FAQ Site
Wrox Press .............. Win32 Scripting Journal
eSolutions Services, LLC

The Surgeon General has determined that prolonged exposure to the Windows Script Host may be addictive to laboratory mice and codemonkeys
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform