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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Remote View and CHeck state

Status
Not open for further replies.

ryupb

MIS
Aug 31, 2004
25
US
Hi,

I am trying to create an sql remote view from an sql server... this part is ok, but is there a way for me to check the state of the fetch??

You see, when I create a remote view programmatically the code runs smooth, but I need to know if all records has already been gathered or if the code is still executing...

anybody??
 
Here is an example of code that I am using to determine when the Fetch has completed...

Code:
USE orders ALIAS orders IN 0  && Remote View into "Alien" DBC
SELECT orders
* --- Wait For ALL Records To Be Fetched ---
=CURSORSETPROP("FetchSize",-1,"orders")

* --- Check progress of Fetch ---
LabelHand = CURSORGETPROP("ConnectHandle","Orders")
DO WHILE SQLGETPROP(LabelHand,"ConnectBusy")
   =INKEY(3,"H")
ENDDO

* --- Fetch Complete Now ---
SELECT orders
INDEX ON agent_code + APPL TAG KEY
CURSORSETPROP('Buffering',5,'orders') && Set buffering to optimistic table
SELECT orders

Good Luck
JRB-Bldr
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top