As per the answers in comment section. There are 2 ways this can be achieved:
Going with the second way, suppose below are the operations we want to perform (IRL I had some complex SPs but let's consider this for now)
INSERT INTO ValueTable VALUES(1);
INSERT INTO ValueTable VALUES(2);
Then we can start a transaction and execute these changes as below
BEGIN TRANSACTION;
INSERT INTO ValueTable VALUES(1);
INSERT INTO ValueTable VALUES(2);
SELECT * FROM TABLENAME;
We can see the logs generated by these operations and decide if we want to proceed or revert by running COMMIT
or ROLLBACK
respectively as @siggemannen mentioned.