Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SKIP 1, GO TOP etc aginst a SQL Server from VFP
Message
From
11/10/2000 00:24:52
 
 
To
10/10/2000 18:02:05
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Miscellaneous
Thread ID:
00427178
Message ID:
00427702
Views:
14
>>Has someone done a function that moves through a table on SQL Server from VFP (with SQLExec())? I have looked a bit at the T-SQL command FETCH but I can't get it to work...
>
>Generally you want to process a 'set' of records, rather than one at a time.. however, it is possible to move through the records precessing each.
>
>What is it you are trying to acomplish, there may be a way you can do it with a SQL statement or corrolated queries, etc. Worst comes to worst, you can use a cursor.
>

I'm createing a function that takes three parameters lcAction, lcCurIdKey, lcNewIdKey. lcAction could be TOP, BOTTOM, NEXT, PREV. lcCurIdKey is the idkey I'm currently using and lcNewIdKey is the new idkey that I will use. The stored procedure should first move the record pointer to lcCurIdKey (and this is the part where I want to move the record pointer as fast as possible) and then do a FETCH NEXT or FETCH PRIOR to get the new idkey and return it to me in lcNewIdKey...
---( Mårten Törnquist )---
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform