The common difference between mysql and oracle database

Differences: (I provide common differences, do not like do not spray)

1. mysql is open source and free of charge. It takes up little space for general applications and small companies. Oracle is chargeable and takes up storage.

Large space, generally used in large companies commonly found in major operators, banks and governments

2. Transaction submission method

Oracle does not automatically submit by default, users need to manually submit.

MySQL default is automatically submitted. Does not support transactions.

mysql automatically submits by default, that is, you submit a query, it will be executed directly, we can pass.

set autocommit = 0 Disable automatic submission.

set autocommit = 1 Turn on autocommit.

3. Processing of single quotes

You can use double quotes to enclose a string in MYSQL, and only single quotes to enclose a string in ORACLE. The single quote must be replaced before inserting and modifying the string: replace all single quotes that appear with two single quotes

For example, a sql statement select * from user a where a.id = '1' single quotes, both are recognized. If a.id = "1", only mysql can recognize

4. Expansion and flexibility of SQL statements

mysql has many very practical and convenient extensions to the sql statement, such as the limit function, insert can insert multiple rows of data at a time, select some management data without adding from

5. Fuzzy comparison of strings The field name like '% string%' is used in MYSQL, and the field name like '% string%' can also be used in ORACLE, but this method can not use the index, the speed is not fast

6. Oracle implements most of the functions in ANSII SQL, such as transaction isolation level, propagation characteristics, etc. Mysql is still relatively weak in this regard

Published 13 original articles · Likes0 · Visits 1942

Guess you like

Origin blog.csdn.net/Beautifulcoco/article/details/103595310