Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Remote View updates.
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00258409
Message ID:
00258682
Views:
22
Tom,

I would start by simplifying your test a bit. Just USE the view in the command window and browse it. Make a change and try a TABLEUPDATE(). If TABLEUPDATE() returns .F., use AERROR() to see what error the ODBC driver returned.

Make sure in the view designer that you've checked all the fields you want updated. Unless you're using identity fields you should include the key field(s) as fields that should be updated.

>>>I've been through a long list of postings about this issue and still don't understand all I know about how remote views work.
>>>
>>>I am using Visual Foxpro 6.0 with a SQL Server back end. The tables on the server all have key fields, the remote views all have the SQL update properties set, I have a good connection in the database, but I can't get the SQL tables to reflect new records or changes.
>>>
>>>Can someone walk me through how to set up a remote view, and then make sure it talks to the database?
>>>
>>>TIA!
>>>Tom.
>>
>>1. Are you using the View designer?
>>
>YES. I created a database, added a connection, and created the views. I then built the form and added a dataenvironment that included the views. I added the controls to the form and selected their control sources from the combobox in the properties window. I also set relationships between the views in the load event of the form. All seems to work well with moving around in the views
>and displaying the data. I have an 'Add' button that does INSERT INTO the approriate views when I need to add records, and a 'Save' button that does the tableupdate() for each view in succession. If I browse the views in the dataenvironment, all my modifications appear as I would expect. They just don't go out to SQL Server. Of course, when I close down the form designer and come back in, the views are reflective of the SQL Server data tables and have lost my changes.
>
>>2. Have you turned on the 'send updates'.
>>
>YES.
>
>>3. Have you done a tableupdate() to send the updates, then a requery() to see if they are on the back end?
>>
>YES to the tableupdate() and NO to the Requery(). I have gone out in SQL Executive and looked at the tables though.
>
>>4. Are you loggin on to the SQL server with an account that has writes to do the update?
>>
>YES I have all necessary rights to the SQL database. I am using ODBC with a machine DSN which connects properly.
>
>>BOb
>
>There has to be something I'm missing. I just can't see it.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform