The difference between MySQL and Oracle

 

  Since SQL Server is not commonly used, here is only the difference between MySQL database and Oracle database

(1) For transaction submission
    , MySQL defaults to automatic submission, while Oracle does not automatically submit by default. Users need to submit manually, and they need to write the commit; command or click the commit button
(2) For paging query
    MySQL, write "select" directly in the SQL statement ... from ...where...limit x, y", paging can be achieved with limit; while Oracle needs to use pseudo-column ROWNUM and nested queries
(3) Transaction isolation level
      MySQL is read committed isolation level, while Oracle is the isolation level of repeatable read, and Oracle supports the isolation level of serializable, which can achieve the highest level of
    read consistency. After each session is submitted, other sessions can see the submitted changes. Oracle achieves read consistency by constructing multi-version data blocks in the undo tablespace.
    When querying each session, if the corresponding data block changes, Oracle will construct the old data for this session in the undo tablespace when it is queried. Block
    MySQL does not have a mechanism for constructing multi-version data blocks similar to Oracle, and only supports the isolation level of read committed. When a session reads data, other sessions cannot change the data, but
    can insert data at the end of the table. When a session updates data, an exclusive lock must be added, and other sessions cannot access the data
(4) Support for transactions
    MySQL can only support transactions in the case of row-level locks in the innodb storage engine, while Oracle fully supports transactions
(5) save data persistence
    MySQL will lose data when the database is updated or restarted. Oracle writes the submitted SQL operation line into the online online log file, and keeps it on the disk, which can be restored at any time.
(6) Concurrency
    MySQL mainly uses table-level locks. The granularity of resource locking is very large. If a session locks a table for too long, other sessions cannot update the data in this table.
  Although the table of the InnoDB engine can use row-level locks, the mechanism of this row-level lock depends on the index of the table. If the table does not have an index, or the SQL statement does not use an index, then the table-level lock is still used.
  Oracle uses row-level locking, and the granularity of resource locking is much smaller. It only locks the resources required by SQL, and the lock is on the data row in the database, and does not depend on the index. So Oracle's support for
  concurrency is much better.
(7) Logical backup
    The data must be locked during logical backup of MySQL to ensure that the backed up data is consistent, which affects the normal use of dml in the business. Oracle logical backup does not lock the data, and the backed up data is consistent
(8) Copy
    MySQL: copy The server configuration is simple, but when the main database fails, the cluster database may lose some data. And need to manually switch the cluster library to the main library.
    Oracle: There are both push or pull traditional data replication, and dataguard's dual or multi-machine disaster recovery mechanism. If there is a problem with the main database, the standby database can be automatically switched to the main database, but the configuration management is more complicated.
(9) Performance diagnosis
    MySQL has few diagnosis and tuning methods, mainly slow query logs.
    Oracle has a variety of mature performance diagnosis and tuning tools, which can realize many automatic analysis and diagnosis functions. Such as awr, addm, sqltrace, tkproof, etc.    
(10) Permissions and security
    The user of MySQL is related to the host, and it feels meaningless. In addition, it is easier to be counterfeited by the host and ip.
    Oracle's permissions and security concepts are more traditional and quite satisfactory.
(11) Partition table and partition index
    MySQL's partition table is not yet mature and stable.
    Oracle's partition table and partition index functions are very mature, which can improve the user experience of accessing db.
(12) Management
    tools There are few MySQL management tools, and the installation of management tools under linux sometimes requires the installation of additional packages (phpmyadmin, etc), which is complicated.
    Oracle has a variety of mature command line, graphical interface, web management tools, and many third-party management tools, management is extremely convenient and efficient.
(13) The most important difference
    MySQL is a lightweight database, and free, no service to restore data.
    Oracle is a heavy duty database, for a fee, Oracle Corporation has any services for Oracle database.

  Since SQL Server is not commonly used, here is only the difference between MySQL database and Oracle database

(1) For transaction submission
    , MySQL defaults to automatic submission, while Oracle does not automatically submit by default. Users need to submit manually, and they need to write the commit; command or click the commit button
(2) For paging query
    MySQL, write "select" directly in the SQL statement ... from ...where...limit x, y", paging can be achieved with limit; while Oracle needs to use pseudo-column ROWNUM and nested queries
(3) Transaction isolation level
      MySQL is read committed isolation level, while Oracle is the isolation level of repeatable read, and Oracle supports the isolation level of serializable, which can achieve the highest level of
    read consistency. After each session is submitted, other sessions can see the submitted changes. Oracle achieves read consistency by constructing multi-version data blocks in the undo tablespace.
    When querying each session, if the corresponding data block changes, Oracle will construct the old data for this session in the undo tablespace when it is queried. Block
    MySQL does not have a mechanism for constructing multi-version data blocks similar to Oracle, and only supports the isolation level of read committed. When a session reads data, other sessions cannot change the data, but
    can insert data at the end of the table. When a session updates data, an exclusive lock must be added, and other sessions cannot access the data
(4) Support for transactions
    MySQL can only support transactions in the case of row-level locks in the innodb storage engine, while Oracle fully supports transactions
(5) save data persistence
    MySQL will lose data when the database is updated or restarted. Oracle writes the submitted SQL operation line into the online online log file, and keeps it on the disk, which can be restored at any time.
(6) Concurrency
    MySQL mainly uses table-level locks. The granularity of resource locking is very large. If a session locks a table for too long, other sessions cannot update the data in this table.
  Although the table of the InnoDB engine can use row-level locks, the mechanism of this row-level lock depends on the index of the table. If the table does not have an index, or the SQL statement does not use an index, then the table-level lock is still used.
  Oracle uses row-level locking, and the granularity of resource locking is much smaller. It only locks the resources required by SQL, and the lock is on the data row in the database, and does not depend on the index. So Oracle's support for
  concurrency is much better.
(7) Logical backup
    The data must be locked during logical backup of MySQL to ensure that the backed up data is consistent, which affects the normal use of dml in the business. Oracle logical backup does not lock the data, and the backed up data is consistent
(8) Copy
    MySQL: copy The server configuration is simple, but when the main database fails, the cluster database may lose some data. And need to manually switch the cluster library to the main library.
    Oracle: There are both push or pull traditional data replication, and dataguard's dual or multi-machine disaster recovery mechanism. If there is a problem with the main database, the standby database can be automatically switched to the main database, but the configuration management is more complicated.
(9) Performance diagnosis
    MySQL has few diagnosis and tuning methods, mainly slow query logs.
    Oracle has a variety of mature performance diagnosis and tuning tools, which can realize many automatic analysis and diagnosis functions. Such as awr, addm, sqltrace, tkproof, etc.    
(10) Permissions and security
    The user of MySQL is related to the host, and it feels meaningless. In addition, it is easier to be counterfeited by the host and ip.
    Oracle's permissions and security concepts are more traditional and quite satisfactory.
(11) Partition table and partition index
    MySQL's partition table is not yet mature and stable.
    Oracle's partition table and partition index functions are very mature, which can improve the user experience of accessing db.
(12) Management
    tools There are few MySQL management tools, and the installation of management tools under linux sometimes requires the installation of additional packages (phpmyadmin, etc), which is complicated.
    Oracle has a variety of mature command line, graphical interface, web management tools, and many third-party management tools, management is extremely convenient and efficient.
(13) The most important difference
    MySQL is a lightweight database, and free, no service to restore data.
    Oracle is a heavy duty database, for a fee, Oracle Corporation has any services for Oracle database.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325688159&siteId=291194637