INNER JOIN

SQL INNER JOIN 关键字

August 28, 2022
Sql, JOIN, 连接, INNER JOIN, INNER

SQL INNER JOIN 关键字 # INNER JOIN 关键字在表中存在至少一个匹配时返回行。 SQL INNER JOIN 语法 # SELECT column_name(s) FROM table1 INNER JOIN table2 ON table1.column_name=table2.column_name; 或: SELECT column_name(s) FROM table1 JOIN table2 ON table1.column_name=table2.column_name; 注释:INNER JOIN 与 JOIN 是相同的。 SQL INNER JOIN 实例 # MariaDB [learnsql]> select domains.id,domains.domainname,logs.baidu,logs.google from domains inner join logs on domains.id=logs.id order by logs.google; +----+---------------+--------+--------+ | id | domainname | baidu | google | +----+---------------+--------+--------+ | 47 | manjushri. ...