Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
One remote view, many identical source tables: how to do
Message
 
 
To
04/06/2002 17:54:15
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00664726
Message ID:
00664757
Views:
20
The problem with that in a multi user environment is that you have the potential of user A setting the connection for one DB, user B wanting to open the same view but to another DB but the view ispoint to DB for user A. YOu either need to come up with a locking scheme on a local table that is commonly open for all users where you lock the table while the view is opened then unlock the table [really not practical] or create a local DBC for each user that has all the view definitions in there. You would of course create the views based on the connection they need and there will be no need to continually swap connections. You can use GENDBC to generate the code you need to do this. I should have suggested this first.

>I will try out the information which you provided. Thanks.
>
>I have also discovered that I was probably going about things incorrectly. I had set up 16 different named connections, one for each of the 16 databases. I had set up a single remote view. Apparently, once a remote view is set up, it retains the connection name. I tried (unsuccessfully) to get the remote view to accept a different connection. Instead, I can use DBSETPROP to change the details of the named connection to which the view is linked. Before I attempt to open the view, I simply pass whichever connection string is appropriate for that company division, to DBSETPROP. That seems to achieve what I needed.
>
>Best wishes,
>Randy
Mark McCasland
Midlothian, TX USA
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform