>I have a view (lv_employee_u) based on employee table. The SEND SQL UPDATE box is check marked in my view. Here is the code I use to update:
>
>r1 = cursorsetprop('sendupdates', .t.,'lv_employee_u')
>for aa = 1 to l
>if a__gen20[aa,1] <> .a__gen10[aa,1]
>update lv_employee_u set lv_employee_u.e_cto = p ;
>where lv_employee_u.e_id = r
>yyy = tableupdate(.t.,.t.,'lv_employee_u')
>endfor
>
>the variable yyy returns a .t., yet my underlying table never update with new value. I have never been able to make this work, isn't it possible to update main tables through view???
>
Have you verified the values in the view before you attempt your tableupdate? Try altering the values with xBase (REPLACE) commands instead of SQL.
In addition to checking "Send SQL Updates", you need to make sure that the fields you want to update are checked in the field list, and your primary key is specified.
Erik Moore
Clientelligence