General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
In my data environment I have 2 views. I have lv_cto_u which I do INSERT command (The INSERT works fine). The Second View in my data environment is lv_employee_u which I do UPDATE command (this one is the one thats failing to update the core table). The form is set to private datasession and pessemistic buffermode. Do you mean double buffer as in I can't have two views existing in data environment? I am doing tableupdate at end of FOR loop and the insert seems to work. I am also doing tableupdate for UPDATE command while in for loop and that doesn't seem to work. I have even tried tableupdate on the core table employee (for view lv_employee_u) and that didn't work. I don't seem to understand double buffer.
for aa = 1 to l
h = .a__gen10[aa,1] &&old snapshot cto
p = a__gen20[aa,1] &&new snapshot cto
q = a__gen20[aa,2] &&mew snapshot cto date
r = a__gen20[aa,6] &&new snapshot id
if a__gen20[aa,1] <> .a__gen10[aa,1]
insert into lv_cto_u (c_e_id, c_oldcto, c_newcto, c_date);
values (r,h,p,q)
update lv_employee_u set lv_employee_u.e_cto = p where lv_employee_u.e_id = r
xxx = tableupdate(.t.,.t.,'lv_employee_u')
endif
endfor
yyy = tableupdate(.t.,.t.,'lv_cto_u')
THANKS
nick patel
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only