Hi all,
I was wondering if it is possible to perform an inner select in MySQL.
I have a database called EMP and when i enter the following query, I
keep getting error 1064:
select ename,deptno from emp where deptno in (select deptno from emp
where ename = 'SCOTT')
The error message reads as
Michael Beaucourt wrote:
Hi all,
I was wondering if it is possible to perform an inner select in MySQL.
I have a database called EMP and when i enter the following query, I
keep getting error 1064:
select ename,deptno from emp where deptno in (select deptno from emp
where ename =
no mysql right now (3.23) does not support inner selects.
however, it looks like you could join the 2 tables to get the result you
want
I'm assuming there are 2 tables inside the emp database ? or is emp the
table ?
anyway here is an idea:
select d1.ename, d1.deptno FROM emp.table1 d1
Michael Beaucourt wrote:
Hi all,
I was wondering if it is possible to perform an inner select in MySQL.
I have a database called EMP and when i enter the following query, I
keep getting error 1064:
select ename,deptno from emp where deptno in (select deptno from emp
where ename =
Hi,
- In oracle you have outer joins, where you have to use a (+)
to find rows with null values and stuff like that. Any suggestions on
how to do this in MySQL?
You must use the Left Join type syntax in the FROM clause of your query.
- The function UNION to connect 2 select queries
On Mon, Aug 27, 2001 at 07:28:24PM +0200, Bruce Stewart wrote:
- The function UNION to connect 2 select queries also doesn't
seem to work in MySQL. Any workarounds?
I believe, not yet supported in MySQL.
It's was in the 4.0 tree last I looked, so it won't be long. :-)
Jeremy
--