Hi, before adding any new master record, why not add this begin transaction
with this option, you can have option to commit or rollback to last change.
-----------------------------------------
'is to have option for rollback
begin transaction
insert into tblSalesman (code, name, deptcode, branchcode, runningCode, runningNo, deleted, insertedby)
values ('YY', 'Yeong', 'IT', 110,'SA/N/YK', 1, 0, 1);
with this option, you can have option to commit or rollback to last change.
-----------------------------------------
'is to have option for rollback
begin transaction
insert into tblSalesman (code, name, deptcode, branchcode, runningCode, runningNo, deleted, insertedby)
values ('YY', 'Yeong', 'IT', 110,'SA/N/YK', 1, 0, 1);
' is to rollback last change
begin transaction
begin transaction
rollback
;is to confirm commit
begin transaction
commit
* once commit, no rollback is applicable
TQ
No comments:
Post a Comment