当前位置:网站首页>13 differences between MySQL and Oracle
13 differences between MySQL and Oracle
2022-07-28 16:49:00 【Gemcoder】
One 、 concurrency
Concurrency is the most important feature of database , But concurrency involves the acquisition of resources 、 Sharing and locking .
mysql:mysql Mainly table lock , The granularity of resource locking is very large , If one session Locking a watch for too long , Will let others session Unable to update data in this table . although InnoDB The table of the engine can use row level lock , But the mechanism of this row level lock depends on the index of the table , If the table has no index , perhaps sql The statement does not use an index , Then still use table level locks .
oracle:oracle Using row level locks , The granularity of resource locking is much smaller , It's just locking sql Resources needed , And the lock is on the data row in the database , Independent of index . therefore oracle Support for concurrency is much better .
Two 、 Uniformity
mysql:mysql There's nothing like oracle A mechanism for constructing multi version data blocks , Only support read commited Isolation level . One session When reading data , other session Can't change data , But you can insert data at the end of the table .session When updating data , To add an exclusive lock , other session Unable to access data .
oracle:oracle Support serializable Isolation level , The highest level of read consistency can be achieved . Every session Others after submission session To see the submitted changes .oracle By means of undo Construct multi version data blocks in table space to achieve read consistency , Every session When inquiring , If the corresponding data block changes ,oracle Will be in undo For this... In the table space session The old data block when constructing its query .
3、 ... and 、 Business
mysql stay innodb Transactions are only supported when the row level lock of the storage engine .
oracle Fully support affairs very early .
Four 、 Data persistence
mysql: Default submit sql sentence , But if something happens during the update process db Or the host restarts , Data may be lost .
oracle: Ensure that the submitted data can be recovered , because oracle Put the submitted sql The operating line is written to the online log file , Keep it on disk , In case of abnormal restart of database or host , After restart oracle You can rely on online logs , Recover the data submitted by the customer .
5、 ... and 、 submission
mysql The default is auto submit .
oracle The default is not auto submit , It needs to be submitted by the user manually .
6、 ... and 、 Logical backup
mysql Lock data during logical backup , To ensure that the backup data is consistent , Affecting the normal business dml Use .
oracle Do not lock data during logical backup , And the backup data is consistent .
7、 ... and 、 Hot backup
mysql:myisam The engine of , use mysql Self contained mysqlhostcopy Hot standby , You need to add a read lock to the table , influence dml operation .innodb The engine of , It backs up innodb Tables and indexes of , But no backup .frm file . use ibbackup When the backup , There will be a log file to record the data changes during the backup , So you don't have to lock the watch , Do not affect other users to use the database . But this tool is free .innobackup Is a combination of ibbackup A script used , He'll help yeah .frm Backup of files .
oracle Have mature hot standby tools rman, Hot standby , It does not affect users' use of the database . Even if the backed up databases are inconsistent , You can also make consistent replies through archived logs and online redo logs during recovery .
8、 ... and 、sql Statement expansion and flexibility
mysql Yes sql Statement has many very practical and convenient extensions , such as limit function ,insert You can insert multiple rows of data at a time ,select Some management data may not add from.
oracle I feel more stable and traditional in this regard .
Nine 、 Copy
mysql: Replication server configuration is simple , But when there's something wrong with the main warehouse , The plex may lose some data . And you need to manually switch the cluster library to the main library .
oracle: There's traditional data replication, push or pull , Also have dataguard The disaster recovery mechanism of dual or multiple computers , When there is a problem in the main warehouse , You can automatically switch the standby database to the main database , But configuration management is more complex .
Ten 、 Performance diagnostics
mysql There are fewer diagnostic tuning methods , There are mainly slow query logs .
oracle There are various mature performance diagnosis and tuning tools , Can realize a lot of automatic analysis 、 Diagnostic function . such as awr、addm、sqltrace、tkproof etc.
11、 ... and 、 Authority and security
mysql The user of is related to the host , It doesn't make any sense , In addition, the host is easier to be imitated ip There is a chance .
oracle The concept of authority and security is more traditional , The compasses .
Twelve 、 Partitioned tables and partitioned indexes
mysql The partition table is not yet mature and stable .
oracle The function of partition table and partition index is very mature , Can improve user access db Experience .
13、 ... and 、 Management tools
mysql Fewer management tools , stay linux Installation of management tools under , Sometimes you need to install additional packages (phpmyadmin,etc), There is some complexity .
oracle There are many mature command lines 、 The graphical interface 、web Management tools , There are also many third-party management tools , Management is extremely convenient and efficient .
边栏推荐
- Multiple commands produce ‘.../xxx.app/Assets.car‘问题
- Wake up after being repeatedly upset by MQ! Hate code out this MQ manual to help the journey of autumn recruitment
- Using pyqt to design gui in ABAQUS
- Implementation of paging
- ANSA二次开发 - 界面开发工具介绍
- MySQL5.7及SQLyogV12安装及使用破解及常用命令
- asp.net大文件分块上传断点续传demo
- Interesting kotlin 0x08:what am I
- HDU1847解题思路
- ABAQUS GUI interface solves the problem of Chinese garbled code (plug-in Chinese garbled code is also applicable)
猜你喜欢

小程序:获取元素节点信息

LeetCode每日一练 —— 剑指Offer 56 数组中数字出现的次数

Sort 3-select sort and merge sort (recursive implementation + non recursive implementation)

快速掌握 Kotlin 集合函数

优化Hypermesh脚本性能的几点建议

Leetcode daily practice - the number of digits in the offer 56 array of the sword finger

Learn ABAQUS script programming script in an hour

有趣的 Kotlin 0x0A:Fun with composition

Interesting kotlin 0x07:composition

QT packaging
随机推荐
Im im development optimization improves connection success rate, speed, etc
排序3-选择排序与归并排序(递归实现+非递归实现)
Reset grafana login password to default password
阿里大哥教你如何正确认识关于标准IO缓冲区的问题
Design direction of daily development plan
LwIP development | socket | UDP
PHP image upload
Early in the morning, pay Bora SMS to say that you won the "prize"? Dealing with server mining virus - kthreaddi
HM二次开发 - Data Names及其使用
MySQL CDC if the binlog log file is incomplete, can you read all the data in the full volume stage
Implementation of transfer business
关于MIT6.828_HW9_barriers xv6 homework9的一些问题
Implementation of paging
Ansa secondary development - Introduction to interface development tools
IM即时通讯软件开发网络请求成功率的优化
在abaqus中使用PyQt设计GUI
Splash (rendering JS service) introduction installation
"Wei Lai Cup" 2022 Niuke summer multi school training camp 3 a.ancestor lca+ violence count
Ansa secondary development - apps and ansa plug-in management
WSL+Valgrind+Clion