Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
This is not shouting. Error: SELECT ... INTO TABLE
Message
 
To
07/09/2005 16:42:11
Jay Johengen
Altamahaw-Ossipee, North Carolina, United States
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
01047494
Message ID:
01047529
Views:
13
This message has been marked as a message which has helped to the initial question of the thread.
...Thanks! But, why did it work?

When OPTIMIZE is on VFP tries to be as fast as it can. As cursors normally are readonly, it can use a trick if the data is requestet in the same format as the source (i.e. no calculated fields, no grouping etc).

so if VFP finds a query like this:
select *;
  from SOURCE;
    where CUSTNO > "1234";
     into cursor DEST_1
it actually does this:
  select 0
  use SOURCE again alias DEST_1
  set filter to CUSTNO > "1234"
  
if it now would allow another ... INTO CURSOR DEST_1, You might ruin Your original data.

You can check by issuing
? dbf( "DEST_1" )
after the query.

So if You really need a cursor to further work with use the NOFILTER clause as the others said, to tell VFP "I do need this for furter work".
Regards from Berlin

Frank

Dietrich Datentechnik (Berlin)
Softwarekombinat Teltow (Teltow)

Frank.Dietrich@dd-tech.de
DFPUG # 327
Previous
Reply
Map
View

Click here to load this message in the networking platform