What is a database transaction?

前端 未结 11 2262
耶瑟儿~
耶瑟儿~ 2020-11-27 09:34

Can someone provide a straightforward (but not simpler than possible) explanation of a transaction as applied to computing (even if copied from Wikipedia)?

11条回答
  •  误落风尘
    2020-11-27 10:18

    I think a transaction is an atomic action in terms of DBMS.

    that means it cannot be seperated. yes, in a transction, there may be several instructions for the system to execute. but they are binded together to finished a single basic task.

    for example. you need to walk through a bridge (let's treat this as a transction), and to do this, say, you need 100 steps. overall, these steps cannot be seperated. when you've done half of them, there is only two choice for you: continue to finish them all, and go back to the start point. it's just like the to result of a transaction: success( committed ) and fail( rollback )

提交回复
热议问题