I have a table emp. There is only one column in the table.
In that , there are only three rows in that column.
The value in the first row is 'A' and the value in the
second row is 'B' and the third row is 'C'. Now, my question
is ,
How will you write a select query to display the output as
B
C
A
Note: order by cannot be used coz it gives us output as CBA.
But the output should be BCA.
Answer Posted / garv
SELECT DECODE (EEE,'A','B','B','C','A') EEE
FROM EMP
--EEE IS COLUMN NAME OF TABLE EMP
Is This Answer Correct ? | 9 Yes | 3 No |
Post New Answer View All Answers
How to export data to a csv file?
How translate command is different from replace?
How to filter out duplications in the returning rows using oracle?
Does oracle charge for java?
From the following identify the non schema object: packages, triggers, public synonyms, tables and indexes.
Is oracle an open source?
What is an Oracle index?
Why cursor variables are easier to use than cursors?
How to join two tables in a single query using oracle?
Explain an exception and its types?
How remove data files before opening a database?
Why do you create or replace procedures rather that drop and recreate.
Explain compound trigger in oracle?
What is a relational database management system?
How to install oracle database 10g xe?