Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> comp.databases.theory -> Re: relational algebra - semi joins

Re: relational algebra - semi joins

From: Laconic2 <laconic2_at_comcast.net>
Date: Mon, 17 May 2004 10:00:47 -0400
Message-ID: <96udnTgDv53UWDXd4p2dnA@comcast.com>


> ok the answer to my question seems to be NO.
> SELECT Dept#, dept_name FROM Depts
> WHERE Depts.Dept# = Employees.Dept#;

Why not:

SELECT DISTINCT dept_no, dept_name
FROM depts, employees
WHERE depts.dept_no = employees.dept_no;

This is just a standard inner join, together with a projection onto the columns in the result. Received on Mon May 17 2004 - 09:00:47 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US