Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Change database in a connection programmatically ?
Message
From
25/06/2001 05:10:38
 
 
To
25/06/2001 04:55:11
General information
Forum:
Visual FoxPro
Category:
Client/server
Miscellaneous
Thread ID:
00518231
Message ID:
00522967
Views:
9
Hi!

Switch off the getting data on-demand (fetch as needed option), download all view data completely to client to finish the view query on SQL Server.

Or just make all views SHARED but the views you want to get data on-demand. However, in this case, you will require to change the database for all connections in all views. This is not easy indeed, because, to change the database, you will require to open all views at startup (except the SHARED views) with NODATA option, than use the SQLEXEC() function to set the 'USE' command to SQL Server for each connection of view, than requery the view. Requery of view will be required each time you switch database, and do not ever close these views.

Above puts significant restrictions to the application architecture and programming. So think twice what is better - do above or just change the application slightly so it do not get so much data at once in remote view (or just get all data, but it might be slow).

HTH.

>Hi, Vlad.
>
>You will get "Connection is busy" error.
Vlad Grynchyshyn, Project Manager, MCP
vgryn@yahoo.com
ICQ #10709245
The professional level of programmer could be determined by level of stupidity of his/her bugs

It is not appropriate to say that question is "foolish". There could be only foolish answers. Everybody passed period of time when knows nothing about something.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform