I have a system that executes certain transactions based on the users selection. So a user can select to create tables, insert data and create a stored procedure etc.
What I would like to do is perform error checking, so if the same table or stored procedure is already created or there is an error in the code, then it should be validated by the error checking.
I have had a look at a couple of code examples on the internet to check for error handling, these examples are only based if I was to perform one action. But if I use the same example on my system then it wouldnt work.
The following are two example codes, one for building a table, the other for creating a stored procedure.
Im, not sure how to go about this, so please help me achieve this. I would like to use Transactions to perform this solution.