Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
View does not update a field in base table
Message
From
10/05/2002 12:00:07
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Other
Title:
View does not update a field in base table
Miscellaneous
Thread ID:
00655112
Message ID:
00655112
Views:
70
Below is code that creates a view. When editing the view through a browse window all field edits get send back to the base table except for the field incidents.employeeid. For some reason this field is not updated to the base table. What is even stranger is that if in the select statement below the parameters
'left outer join data1!employees ;
on incidents.employeeid = employees.employeeid'
are moved to the bottom of the command then this field will get updated. But then the field incidents.jobtitleid ceases to update.
The rule here seems to be that the field involved in the first join condition never gets any updates. What's going on here?


create sql view incidentsview ;
as select incidents.*, ;
employees.claimaintlastname, locationnumbers.number, jobtitles.jobtitle ;
from data1!incidents ;
left outer join data1!employees ;
on incidents.employeeid = employees.employeeid ;
left outer join data1!jobtitles ;
on incidents.jobtitleid = jobtitles.jobtitleid ;
left outer join data1!locationnumbers ;
on incidents.locationnumberid = locationnumbers.locationnumberid

dbsetprop('incidentsview','view','tables','data1!incidents')
dbsetprop('incidentsview', 'view', 'wheretype', 3)

dbsetprop('incidentsview.incidentid', 'field', 'keyfield', .t.)
dbsetprop('incidentsview.employeeid', 'field', 'keyfield', .t.)
dbsetprop('incidentsview.jobtitleid', 'field', 'keyfield', .t.)
dbsetprop('incidentsview.locationnumberid', 'field', 'keyfield', .t.)

dbsetprop('incidentsview.incidentid', 'field', 'updatable', .t.)
dbsetprop('incidentsview.employeeid', 'field', 'updatable', .t.)
dbsetprop('incidentsview.jobtitleid', 'field', 'updatable', .t.)
dbsetprop('incidentsview.locationnumberid', 'field', 'updatable', .t.)

dbsetprop('incidentsview', 'view', 'sendupdates', .t.)


Thanks for any help!
Next
Reply
Map
View

Click here to load this message in the networking platform