Home > Database > Mysql Tutorial > 判断一个表的数据不在另一个表中最优秀方法

判断一个表的数据不在另一个表中最优秀方法

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-07 17:59:38
Original
988 people have browsed it

判断一个表的数据不在另一个表中最优秀方法

代码如下:
table a columns(key,value);
table b columns(key,value);

SELECT a.* FROM a LEFT JOIN b
ON a.key = b.key
WHERE b.key IS NULL

Related labels:
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template