Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

cursor questions

Status
Not open for further replies.

iansr

Programmer
Aug 31, 2001
11
PH
Im a beginner in visual foxpro and the documentation doesnt help.

I have a few questions on cursors:

1. How do i fetch values from it?
How do i do something like this: (IN SQL SERVER)

fetch next cursor_something into iNumber
while(@@fetch_status = 0)
begin

fetch next cursor_something into iNumber
end


2. How do i close/deallocate cursors? (The documentation keeps on saying ....until you close the cursor, but it doesnt say anything about how to close it.)

3. is this possible in vfp?
SELECT cName = Name FROM authors

thanks in advance!
 
1)
SELECT cursor_something
SCAN

ENDSCAN

2)
SELECT cursor_something
USE

-or-

USE IN "cursor_something"

3) cName = authors.Name

Hope this helps,
Bo Durban
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top