Form a inline view based on the results of the previous query?


Posted on 16th Feb 2014 07:03 pm by admin

Hi Experts,
Can we form a inline view on the results of a previous query (another inline view)?

Ex:
Did you know?Explore Trending and Topic pages for more stories like this.
select employees.emp_no,
employees.ename,
departments.dept_no
from
(select dept_no from dept) departments,
(select emp_no, ename from emp) employees
where employees.dept_no = departments.dept_no

In the above example, first the compiler forms 2 inline views employees and departments and then joins these 2 in the where clause.

But can we form the "employees" inline view to have only those rows based on the results of "departments" query.

Thanks
No comments posted yet

Your Answer:

Login to answer
209 Like 16 Dislike
Previous forums Next forums
Other forums

Create comparison matrix?
I want to create a comparison script for forum software and was wondering is there any tutorial or b

FlashVar function how to insert variables
Hi guys. Im new in this forum and also new in php programming. Can you help me about this code?
<

multiple recipients + dbuser mail recall
Hello,

I am building a php login script.

When the user registers the script will send

GMail like Chat in ASP.NET
Hi,Can anyone suggest me, how to incorporate GMail like chat in my existing ASP.Net application.I wa

How to submit a form to the same page?
I have a table containing information about books in my library and this table has the following col

Getting number of affected rows in SQLPLUS..
Hi everyone,
I have a shell script where i am invoking sqlplus, running a query and saving t

PHP / MySQL Associative Multidimensional Array:
Hello.

I have data in a MySQL Table that adheres to the below: (note, no index, could add if

Warning: mysql_num_rows() expects parameter 1
When i add quote at the end of this link
example:http://localhost/articlemania/category.php?cid=3

removing space from the end of a variable
i have a variable $image which contains the following url "http://tiles.xbox.com/tiles/oo/P5/0m

Why does my crawler script suddenly end with no error?
Hi.

I have written a web crawler script. It will visit a large number of URL's with cURL.

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash