when i delete a data that has been deleted from the Data Window but has not been committed to the database. a null row is getting created in database... can anyone help me to solve this problem
Asked
Active
Viewed 89 times
-1
-
Please provide more details. How you delete the data, which database you use? Any code snippet? – Greko2009 Dec 15 '15 at 11:58
-
Greko2009: to delete: ELSEIF key=keyJ! THEN IF dw_detail.getselectedrow(0) = dw_detail.GetRow() THEN dw_detail.scrolltorow (dw_detail.GetRow()) IF isnull( dw_detail.GetItemString(dw_detail.GetRow(),'discrep')) THEN messagebox("Error","No items are found!") else dw_detail.DeleteRow(dw_detail.GetRow() ) dw_detail.SetItemStatus(dw_detail.getselectedrow(0), 0, delete!, dataModified!) il_currentrow -- if dw_detail.Update() =1 then COMMIT USING SQLCA; else messagebox("Warning","Do you want to delete?") end if – Delna Dec 17 '15 at 04:26
-
and i am using sql server – Delna Dec 17 '15 at 04:27
1 Answers
0
try delete simple one row and delete it.
any inserts updates deletes need commit, add this:
if dw.update() = 1 then
commit;
else
rollback;
end if
Happy coding

Masa sih
- 86
- 11