take one table is t1 and in that column name is f1
f1 column values are
200
5000
3000
7000
300
600
100
400
800
400
i want display the values asc and desc in a single output.
sample output is
f1.a
100
200
300
400
500
600
etc......
and f1.d is
5000
4000
3000
2000
1000
etc...
Answer Posted / pooja gupta
select f1.a, f2.d from
(select f1 as a from t order by 1) f1,
(select f1 as d from t order by 1 desc)f2
| Is This Answer Correct ? | 2 Yes | 3 No |
Post New Answer View All Answers
What is the basic structure of an sql?
what is a composite primary key ? : Sql dba
What are properties of the transaction?
How many clustered indexes can you have?
What are types of indexes in sql?
What is date functions?
can a stored procedure call itself or recursive stored procedure? How much level sp nesting is possible? : Sql dba
How do temporal tables work?
How do I start pl sql?
Can cursors be part of a trigger body?
What is the use of sqlerrd 3?
what is sql in mysql? : Sql dba
What are the two virtual tables available at the time of database trigger execution?
Define the select into statement.
What are stuff and replace function?