Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Need Some Explanation on the clause connect by level

Rajan SwApr 11 2017 — edited Apr 11 2017

Hi

When I write  SELECT level FROM dual CONNECT BY LEVEL <=1000 then it is generating numbers from 1 to 1000 and when I check with  SELECT LEVEL FROM dual CONNECT BY LEVEL >1 then I get infinite nos and when I check with the condition with SELECT LEVEL FROM dual CONNECT BY LEVEL >2 or any number then I get only one records .

I am really confused with the working logic behind this . Would anyone please explain me the usages and the differences

I will really appreciate any thoughts on this .

This post has been answered by Frank Kulash on Apr 11 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 9 2017
Added on Apr 11 2017
6 comments
6,969 views