Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback, please email oracle-forums_moderators_us@oracle.com

kind of sequential query

MichaelSFeb 17 2007 — edited Jun 21 2007
Hello folks,

my requirement is: Given a number N (let's say 7 for this example) generate a query with following output:
SELECT A,B FROM some_query
/

A  B
-------
1  7
1  7
1  7
1  7
1  7
1  7
1  7
2  6
2  6
2  6
2  6
2  6
2  6
3  5
3  5
3  5
3  5
3  5
4  4
4  4
4  4
4  4
5  3
5  3
5  3
6  2
6  2
7  1

28 rows selected.
Any ideas?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 18 2007
Added on Feb 17 2007
16 comments
3,263 views