FACTOID # 143: If someone you know died from falling out of a tree, you’re probably Brazilian.
 
 Home   Encyclopedia   Statistics   Countries A-Z   Flags   Maps   Education   Forum   FAQ   About 
 
WHAT'S NEW
RECENT ARTICLES
More Recent Articles »
 

FACTS & STATISTICS    Simple view

  1. Select countries to view: (hold down Control key and click to select several)

     

     

    Compare:

     

     

  1. Select fact or statistic: (* = graphable)

     

     

     

  2. (OPTIONAL) Compare to statistic: (both need to be graphable)

     

     

     

  3. View result as:

     

       
(OR) SEARCH ALL encyclopedia, stats & forums:   

Encyclopedia > Transaction log

In in the field of databases in computer science, a transaction log (also database log or binary log) is a history of actions executed by a database management system to guarantee ACID properties over crashes or hardware failures. Physically, a log is a file of updates done to the database, stored in stable storage. A database is an organized collection of data. ... Computer science, or computing science, is the study of the theoretical foundations of information and computation and their implementation and application in computer systems. ... To meet Wikipedias quality standards, this article or section may require cleanup. ... For other uses, see Acid (disambiguation). ... A crash in computing is a condition where a program (either an application or part of the operating system) stops performing its expected function and also stops responding to other parts of the system. ... A computer file is a collection of information that is stored in a computer system and can be identified by its full path name. ...


If, after a start, the database is found in an inconsistent state or not been shut down properly, the database management system reviews the database logs for uncommitted transactions and rolls back the changes made by these transactions. Additionally, all transactions that are already committed but whose changes were not yet materialized in the database are re-applied. Both is done to ensure atomicity and durability of transactions. In database systems, a consistent transaction is one that does not violate any integrity contraints during its execution. ... In the context of computer science and data management, commit refers to the idea of making permanent a set of tentative changes, such as at the end of a transaction. ... In database technologies, a rollback is an operation which returns the database to some previous state. ... A database transaction is a unit of interaction with a database management system or similar system that is treated in a coherent and reliable way independent of other transactions that must be either entirely completed or aborted. ... In computer science, atomicity implies indivisibility and irreducibility, so an atomic operation must appear to be performed entirely or not at all. ... In computer science, durability is the ACID property that guarantees that transactions that are successfully committed will survive permanently and will not be undone by system failure. ...


This term is not to be confused with normal logs which are generally intended to be verbose and human-readable. Data logging is the practice of recording, in some medium, sequential data, often in a time-associated format. ...


Anatomy of a general database log

A database log record is made up of

  • Log Sequence Number: A unique id for a log record. With LSNs, logs can be recovered in constant time. Most logs' LSNs are assigned in monotonically increasing order, which is useful in recovery algorithms, like ARIES.
  • Prev LSN: A link to the last log record. This implies database logs are constructed in linked list form.
  • Transaction ID number: A reference to the database transaction generating the log record.
  • Type: Describes the type of database log record.
  • information about the actual changes that triggered the log record to be written

Flowcharts are often used to represent algorithms. ... In computer science, Algorithms for Recovery and Isolation Exploiting Semantics, or ARIES is a recovery algorithm designed to work with a no-force, steal database approach. ... In computer science, a linked list is one of the fundamental data structures used in computer programming. ...

Types of database log records

All log records include the general log attributes above, and also other attributes depending on their type (which is recorded in the Type attribute, as above).

  • Update Log Record notes an update (change) to the database. It includes this extra information:
    • PageID: A reference to the Page ID of the modified page.
    • Length and Offset: Length in bytes and offset of the page are usually included.
    • Before and After Images: Includes the value of the bytes of page before and after the page change. Some databases may have logs which include one or both images.
  • Compensation Log Record notes the rollback of a particular change to the database. Each correspond with exactly one other Update Log Record (although the corresponding update log record is not typically stored in the Compensation Log Record). It includes this extra information:
    • undoNextLSN: This field contains the LSN of the next log record that is to be undone for transaction that wrote the last Update Log.
  • Commit Record notes a decision to commit a transaction.
  • Abort Record notes a decision to abort and hence rollback a transaction.
  • Checkpoint Record notes that a checkpoint has been made. These are used to speed up recovery. They record information that eliminates the need to read a long way into the log's past. This varies according to checkpoint algorithm. If all dirty pages are flushed while creating the checkpoint (as in PostgreSQL), it might contain:
    • redoLSN: This is a reference to the first log record that corresponds to a dirty page. i.e. the first update that wasn't flushed at checkpoint time. This is where redo must begin on recovery.
    • undoLSN: This is a reference to the oldest log record of the oldest in-progress transaction. This is the oldest log record needed to undo all in-progress transactions.
  • Completion Record notes that all work has been done for this particular transaction. (It has been fully committed or aborted)

PostgreSQL is a free object-relational database server (database management system), released under a flexible BSD-style license. ...

Tables

These tables are maintained in memory, and can be efficiently reconstructed (if not exactly, to an equivalent state) from the log and the database:

  • Transaction Table: The table contains one entry for each active transaction. This includes Transaction ID and lastLSN, where lastLSN describes the LSN of the most recent log record for the transaction.
  • Dirty Page Table: The table contains one entry for each dirty page that haven't been written to disk. The entry contains recLSN, where recLSN is the LSN of the first log record that caused the page to be dirty.
Topics in database management systems (DBMS)view talk edit )

Concepts
Database | Database model | Relational database | Relational model | Relational algebra | Primary key - Foreign key - Surrogate key - Superkey
Database normalization | Referential integrity | Relational DBMS | Distributed DBMS | ACID To meet Wikipedias quality standards, this article or section may require cleanup. ... A database is an organized collection of data. ... A database model is a theory or specification describing how a database is structured and used. ... A relational database is a database structured in accordance with the relational model. ... The relational model for database management is a data model based on predicate logic and set theory. ... Relational algebra, an offshoot of first-order logic, is a set of relations closed under operators. ... In database design, a primary key is a value that can be used to identify a unique row in a table. ... A foreign key (FK) is a field or group of fields in a database record that point to a key field or group of fields forming a key of another database record in some (usually different) table. ... Dr. E. F. Codd, the creator of the Relational Model defined a surrogate key as ..Database users may cause the system to generate or delete a surrogate, but they have no control over its value, nor is its value ever displayed to them . ... A superkey is defined in the relational model as a set of attributes of a relation for which it holds that in all instances of the relation there are no two distinct tuples that have the same values for the attributes in this set. ... This article or section is in need of attention from an expert on the subject. ... An example of a database that has not enforced referential integrity. ... A relational database management system (RDBMS) is a database management system (DBMS) that is based on the relational model as introduced by Edgar F. Codd. ... According to Elmasri and Navathe (2004, p. ... For other uses, see Acid (disambiguation). ...

Objects
Trigger | View | Table | Cursor | Log | Transaction | Index | Stored procedure | Partition A database trigger is procedural code that is automatically executed in response to certain events on a particular table in a database. ... Originally, in database theory, a view is a read only virtual or logical table composed of the result set of a query. ... In a relational database (RDB), a table is a set of data elements (cells) that is organized, defined and stored as horizontal rows (records) and vertical columns (fields) where each item can be uniquely identified by a label or key or by it’s position in relation to other items. ... In database packages, the term cursor refers to a control structure for the successive traversal (and potential processing) of records in a result set as returned by a query. ... A database transaction is a unit of interaction with a database management system or similar system that is treated in a coherent and reliable way independent of other transactions that must be either entirely completed or aborted. ... An index is a feature in a database that allows quick access to the rows in a table. ... To meet Wikipedias quality standards, this article or section may require cleanup. ... A partition is a division of a logical database or its constituting elements into distinct independent parts. ...

Topics in SQL
Select | Insert | Update | Merge | Delete | Join | Union | Create | Drop
Comparison of syntax SQL (commonly expanded to Structured Query Language — see History for the terms derivation) is the most popular computer language used to create, modify, retrieve and manipulate data from relational database management systems. ... A SELECT statement in SQL returns a result set of records from one or more tables. ... An SQL INSERT statement adds a record to a table in a relational database. ... An UPDATE statement in SQL changes data in one or more records in a relational database management system. ... Wikipedia does not have an article with this exact name. ... A DELETE statement in SQL removes records in a relational database management system. ... A join combines records from two or more tables in a relational database. ... UNION Combines the results of two or more queries into a single result set consisting of all the rows belonging to all queries in the union. ... A CREATE statement in SQL creates an object inside of a relational database management system (RDBMS). ... A DROP statement in SQL removes an object from a relational database management system (RDBMS). ... This article gives a brief summary of various SQL syntax differences used in popular SQL engines: SQLite MySQL PostgreSQL OpenLink Virtuoso Oracle MSSQL // Data structure definition Escaping identifiers A method to somehow escape identifiers (table, column names, etc), so they do not have to obey regular identifier rules, such as...

Implementations of database management systems

Types of implementations
Flat file | Deductive | Dimensional | Hierarchical | Object oriented | Temporal

Products
dBASE | Oracle | Sybase | MySQL | SQLite | Microsoft SQL Server | Essbase | PostgreSQL | DB2 | Helix database | Comparison - relational | Comparison - object-relational A flat file database is described by a very simple database model, where all the information is stored in text files. ... A deductive database system is a database system which can make deductions (ie: infer additional rules or facts) based on rules and facts stored in the (deductive) database. ... A dimensional database is one which, rather than storing data in multiple two dimensional tables (as a relational databases does), represents key data entities as different dimensions. ... To meet Wikipedias quality standards, this article or section may require cleanup. ... An object database is a database in which information is represented in the form of objects. ... A temporal database is a database management system with built-in time aspects, e. ... dBASE III The correct title of this article is dBASE. The initial letter is capitalized because of technical restrictions. ... oracle, see Oracle (disambiguation) An Oracle database, strictly speaking, consists of a collection of data managed by an Oracle database management system or DBMS. The term Oracle database sometimes refers — imprecisely — to the DBMS software itself. ... Sybase SQL Server was the name of Sybase Corporations primary relational database management system product from 1987 to 1995. ... MySQL is a multithreaded, multi-user, SQL Database Management System (DBMS) with more than six million installations. ... SQLite is an ACID-compliant relational database management system contained in a relatively small C library. ... Microsoft SQL Server is a relational database management system (RDBMS) produced by Microsoft. ... Essbase is a multidimensional database management system (MDBMS) that provides a multidimensional database platform upon which to build analytic applications, ie. ... PostgreSQL is a free object-relational database server (database management system), released under a flexible BSD-style license. ... IBMs DB2 product is a database management system. ... Helix is a pioneering database management system for the Apple Macintosh platform. ... It has been suggested that List of relational database management systems be merged into this article or section. ... The following tables compare general and technical information for a number of object-relational database management systems. ...

Components
Query language | Query optimizer | Query plan | ODBC | JDBC
Lists
List of object-oriented database management systems
List of relational database management systems
List of truly relational database management systems Query languages are computer languages used to make queries into databases and information systems. ... The query optimizer is a component of database management system that is used to analyzes queries submitted to database server for execution, and then determines the optimal way to execute the query. ... A query plan (or query execution plan) is an set of steps used to access information in a SQL relational database management system. ... In computing, Open Database Connectivity (ODBC) provides a standard software API method for using database management systems (DBMS). ... Java Database Connectivity, or JDBC, is an API for the Java programming language that defines how a client may access a database. ... The following is a list of object-oriented database management systems. ... It has been suggested that List of truly relational database management systems be merged into this article or section. ... It has been suggested that this article or section be merged into List of relational database management systems. ...



 

COMMENTARY     

There are 1 more (non-authoritative) comments on this page

Share your thoughts, questions and commentary here
Your name
Your comments
Please enter the 5-letter protection code

Want to know more?
Search encyclopedia, statistics and forums:

 


Lesson Plans | Student Area | Student FAQ | Reviews | Press Releases |  Feeds | Contact
The Wikipedia article included on this page is licensed under the GFDL.
Images may be subject to relevant owners' copyright.
All other elements are (c) copyright NationMaster.com 2003-5. All Rights Reserved.
Usage implies agreement with terms.