Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Weird BUG in SEEK
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
OS:
Vista
Network:
Windows 2008 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01350643
Message ID:
01350674
Views:
41
>>>I think you meant to say ALWAYS use SEEK() as a function as opposite to command.
>>Nope,
>>I don't know why but I ALWAYS prefer command with full syntax than function:
>>Maybe because when I started to use VFP (5) the function not gives me the right results? I can't remember why, it was so long ago :-)
>>
>>SEEK Someting IN SomeAlias ORDER SomeOrder
>>IF FOUND([SomeAlias])
>>   **
>>ENDIF
>>
>>
>>Maybe I should say "Always use ORDER clause when you use SEEK command" but it's too late :-)
>
>We're using SEEK command (and FIND) only for quick tests in command window. In the code we always use SEEK() as a function. Less lines to type.

The function has the same problem:
CREATE cursor TEMP (Fld1 I)

INSERT INTO TEMP VALUES (100)      
INSERT INTO TEMP VALUES (110)      
INSERT INTO TEMP VALUES (113)      
INSERT INTO TEMP VALUES (115)      
INSERT INTO TEMP VALUES (119)      

INDEX ON Fld1 TAG Temp

? SEEK([100 Test TestMe])
*? FOUND()              && .T. -> what!!!!!!!!!!!!!!!!!

INDEX ON STR(Fld1) TAG Temp
? SEEK(100)
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Reply
Map
View

Click here to load this message in the networking platform