i want to display 1 to 10 numbers using one select statement.
Answer Posted / kriti sinha
For in 10 rows in a single column
select level from dual connect by level<=10
for 10 numbers in a single column
select 1||chr(10)||2||chr(10)||3||chr(10)||4||chr(10)
||5||chr(10)||6||chr(10)||7||chr(10)||8||chr(10)||9||chr(10)
||10 from dual;
For 10 rows in 10 columns
select 1,2,3,4,5,6,7,8,9,10 from dual;
Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
What does a pl/sql package consist of?
What are the different operators available in sql?
What is the difference between clustered and non-clustered indexes?
who introduced sql?
What are the types of dbms?
how to extract a unit value from a date and time? : Sql dba
Can we use pl sql in mysql?
What is union, minus and interact commands?
Are there any features that are decommissioned in 11g that are not present in 11g?
Can %notfound return null after a fetch?
What is rownum in sql?
what is the difference between group by and order by in sql? : Sql dba
Do we need commit after truncate?
Can we rollback truncate?
How do I count duplicates in sql?