Answer Posted / thanjairajan@gmail.com
The WITH clause may be processed as an inline view or resolved as a temporary table. The advantage of the latter is that repeated references to the subquery may be more efficient as the data is easily retrieved from the temporary table, rather than being requeried by each reference.
For example:
WITH dept_count AS (
SELECT deptno, COUNT(*) AS dept_count
FROM emp
GROUP BY deptno)
SELECT e.ename AS employee_name,
dc.dept_count AS emp_dept_count
FROM emp e,
dept_count dc
WHERE e.deptno = dc.deptno;
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
what is the procedure for scheduling conditional rendering?
What do you understand by user class in cognos?
What do you understand by the term 'dynamic cube'?
What you mean by drill across?
how to test reports in cognos?
what are the names of the reports that you prepared?
Define report item?
What is a Query Subject?
What is difference between primary key and unique key constraints?
Can you explain the advantage of using shortcuts?
Explain the different types of views used in cognos.
What junk dimension contains?
What is the difference between Open Connection command ang Open Session Command?
What is cognos powerhouse?
What are query items?