Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using Seek
Message
From
01/06/2004 21:34:52
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
01/06/2004 08:03:33
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00908842
Message ID:
00909117
Views:
11
>Hi toall,
>
>i have a table1 with an index 'item', my problem is how seek all items starting in 4th position to the 8th positon without changing my index?
>e.g
>abc14421xyz01
>i need to seek all 1442 using seek statement and not select statement.

If you need to do something with these records, you can still use a select statement to find out which records are these:
select item, recno() as rcn from table1;
   where subs(item,4)='1442' into cursor t1
scan
   select table1
   go t1.rcn
* do something here
endscan
Be warned that the use of recno() (as goes for any other function which takes an alias for a parameters) is warranted only because we are having a single table in the select. With more than one table, it wouldn't work as is - then we'd have to split that into a select from a single table into a cursor, and then from that cursor with other tables into the final cursor.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Reply
Map
View

Click here to load this message in the networking platform