session與transaction的區別

tonywi888發表於2008-03-18

session:使用者對資料庫的連線

A session is a specific connection of a user to an Oracle instance through a user process. For example, when a user starts SQL*Plus, the user must provide a valid username and password, and then a session is established for that user. A session lasts from the time the user connects until the time the user disconnects or exits the database application.

transaction:簡單的說就是從開始或上一次commit起,到這次commit為止,當然有些命令是隱含commit的。

A transaction is a logical unit of work that comprises one or more SQL statements executed by a single user. According to the ANSI/ISO SQL standard, with which Oracle is compatible, a transaction begins with the user’s first executable SQL statement. A transaction ends when it is explicitly committed or rolled back by that user.

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/8570952/viewspace-209638/,如需轉載,請註明出處,否則將追究法律責任。

相關文章