In my application I had a form where i have to do more than one database transaction within a single button click ie When I click button
Query 1 >>>insert designation values to Designation table
query 2. >>select query to get the primary key of last entered designation.... ie .the auto number against which the above insert query inserts
query 3 >> inset data into another table with the primary key recvd from above
query 4 .>> update another table with the primary Key Above
If any of the query fails or any exception occur The others shouldnot work
now I am trying to do it using try catch and deleting prevoius insertions if exception occurs...
Is there any good Ideas as I am new to sql server 2008