Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Remote view question
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00456273
Message ID:
00456283
Views:
20
I have run into the same problem, although I am lucky in that my tables do not change that frequently. I do not have any code that automagically updates a view, but here is what I do to avoid the SELECT * problem, which happens when the base table changes:

1. Create my view with the View Designer
2. Switch the order of the fields in the SELECT list, so that SELECT * is not used.
3. Run GenDBC to create a prg that contains the view definitions
4. Copy the view definition code to my views.prg program
5. Change the view definitions so that the views SHARE the REMOTE CONNECTION
5. Make further changes to the view in code.

Of course, having a tool that would do this automagically would be nice < g >.

>I'm a relative newbie when it comes to dealing with SQL Server and I've run into a problem that I thought someone here might be able to help with.
>
>I'm working with some folks on a new system where the data is being stored on SQL Server 7.0 in six different databases. Of these, 5 contain the same tables. The 5 represent 5 different manufacturing facilities. As a result I've created VFP databases containing remote views to the tables.
>
>The problem is that because the system is still under development, the underlying table structures are subject to change. This wouldn't be a big deal if I didn't have to go through the process of updating the individual views 5 times. Is there any easy way to programmatically do this? Right now, I have to manually modify the view and save the changes in order to update it. I'm just looking for something simpler that I could knock out a couple of lines of code to do this.
>
>tia,
Chris McCandless
Red Sky Software
Previous
Reply
Map
View

Click here to load this message in the networking platform