Reply to post: Re: @werdsmith

You had one job... Just two lines of code, and now the customer's Inventory Master File has bitten the biscuit

Anonymous Coward
Anonymous Coward

Re: @werdsmith

I always write a select statement first, then wrap the update in a transaction

Yes, BEGIN TRAN has saved my arse more times than I care to admit.

Though there was the time when someone (a friend, of course) forgot to COMMIT TRAN which left a lock on the database, and they didn't realise till alerts started coming in because the application servers couldn't do DB updates so weren't responding to requests. Oops!

Since then yours truly my friend always does a second COMMIT before closing the DB session in case the first one was forgotton...

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon