Write the sql query using dual table for below output?

1 L R
--- --- ----
1 1 1
1 2 1
1 3 1
1 1 2
1 2 2
1 3 2
1 1 3
1 2 3
1 3 3

Write a query using only Dual table with out writing any pl/sql program.

Answer Posted / abilash reddy

SELECT 1, L, R FROM (SELECT LEVEL R FROM DUAL CONNECT BY LEVEL<=3), (SELECT LEVEL L FROM DUAL CONNECT BY LEVEL<=3);

Is This Answer Correct ?    14 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the two types of exceptions.

635


What is difference between function and trigger?

546


i have some prob lem to tell me about my self in interview first round ...

1706


What is clause?

610


How to change sql*plus system settings?

544






Can I create table without primary key?

531


How can we connect an Android App to an Oracle database and use the PL/SQL procedural code?

584


What is the most restrictive isolation level? : Transact sql

557


What is execute immediate?

549


How is data stored on a disk?

542


Can we insert in sql function?

551


How can triggers be used for the table auditing?

594


How to avoid using cursors? What to use instead of cursor and in what cases to do so?

605


What are commit, rollback, and savepoint?

571


how many tables will create when we create table, what are they? : Sql dba

544