Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Connection & Remote Views
Message
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00235859
Message ID:
00236697
Views:
16
The way reomte views work is that the connection is maintained during the entore life of the view that is open or at least until the last view using a shared connection is closed. This generally is not a performance issue because once the view is established the only server activity is when you are requerying the view or preforming a TableUpdate.

While my connections are to Oracle via TCP/IP connection, I am taking advantage of internet technology, but I am not continuously consuming an internet server's resources except for 1 shared connection and when I am doing the two operations described above.

If you lose a connection, you may as well revert the tables, exit gracefully as possible then try to re-establish communications.

>I am not having the problem right now. I am just wondering what happend if I use remote views for a VFP application that uses the Internet as the network. Chances are that I won't be able to keep the connection open as longer as I need.
>
>I know that if the application is going to run over the Internet then it is better to connect, get data and then disconnect. Then, if the user wants to save his/her changes then I need to (re)connect, send data and then disconnect.
>
>Seems like if I cannot make a remote view to use another connection then they are not a good idea for an Internet application (I better use SPT or ADO). What a shame, they are just great without that "little" issue. Aren't they?
>
>By the way, If I connect to thse server, open my remote view (with shared connection), disconect and then connect again to the server then the view does NOT work - no matter if the connection handle that I get in the second connect is the same as the first one.
>
>
>>>Is there a mechanism to re-establish the connection used in a Remote View if for some reason I lost it?
>>>
>>>use myremoteview
>>>? cursorsetprop( 'connecthandle' ) && 3
>>>
>>>* ...
>>>* do some process here
>>>* (for some reason I lost my connection)
>>>* ...
>>>
>>>
>>>* Here I know that my connection is not longer
>>>* valid. How can I re-establish it and bound it
>>>* to the remote view (actually to the cursor)
>>>* before I do a tableupdate() ?
>>
>>You may be out of luck unless you can use SQLExec() to create a connection that returns a connect handle equal to the one in the voew you opened. If you are losing the connection while the view is still open, you are having problems beyond VFP. Do you know why you are losing this connection? I some other piece of VFP code closing this connection? In your Tools/Options/Remote Data, do you default views to Share Connection? When you create SQL View programmatically, do you specify the view to use a shared connection?
Mark McCasland
Midlothian, TX USA
Previous
Reply
Map
View

Click here to load this message in the networking platform