Mysql join query 1. Basic concepts Connect each row of the two tables horizontally in pairs to obtain the results of all rows. Assumptions:
2. The result after they are connected is similar to this: 3. Basic form of join query: from table 1 [join method] join table 2 [on join condition] Basic form of join query: from table 1 [join method] join table 2 [on join condition] 1. Classification of connection queries Cross Connect In fact, it is the "all data" obtained after connecting two tables according to the basic concept of connection, without any "filtering" result - filtering refers to the connection condition. That is, a cross join is an unconditional "join all" - also known as a Cartesian product. Cross joins usually have no practical value because after joining the data, the meaning of each row of data may be "lost". form:
or:
Inner Join form:
meaning: Get the data of the rows that meet the set connection conditions (the conditions after on) in the result of a "cross connection"; Cross joins often have "meaningless data", as follows: 2. Look at the results of the inner connection: 3. The result is: 4. It can be seen that inner join is actually to find the "meaningful" data rows in the data results of a cross join. In a cross join, some of the data are meaningful, while some are meaningless (erroneous data). However, please note:
You may also be interested in:
|
<<: CentOS7 installation GUI interface and remote connection implementation
>>: JavaScript canvas to achieve raindrop effect
Table of contents Preface Array.prototype.include...
1. Command Introduction The gzip (GNU zip) comman...
describe When calling this interface, you need to...
By default, Nginx supports only one SSL certifica...
Table of contents 1.kvm deployment 1.1 kvm instal...
I recently used the ssm framework when doing a pr...
Table of contents Overview 1. useState 1.1 Three ...
Table of contents Overview 1. RangeError 2. Refer...
Table of contents 1 A brief introduction to syste...
The <a> tag is mainly used to define links ...
Database stored procedures DROP PROCEDURE IF EXIS...
1. Download and unzip to: /Users/xiechunping/Soft...
Without further ado, I will post the code for you...
Table of contents 1. Preface 2. Find two pop-up c...
Last time, we came up with two header layouts, on...