Login | Register   
LinkedIn
Google+
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


Tip of the Day
Language: SQL
Expertise: Intermediate
Nov 1, 2016

Using the SQL MINUS Operator

The SQL MINUS operator makes use of two SQL statements. It takes all the results from the first statement and subtracts out the ones that are present in the second statement to get the final answer.

A quick look at how it works:

SELECT expression1, expression2, ... 
FROM table1
MINUS
SELECT expression1, expression2, ... 
FROM table2

This will show you all the records that do not match the data in the second table

Hannes du Preez
 
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap
Thanks for your registration, follow us on our social networks to keep up-to-date