SELECT * FROM
(SELECT TITLE FROM MOVIE ORDER BY RANK DESC)
WHERE ROWNUM > 4;

when i run the above query .it produces output as NO ROWS
SELECTED.why ?plz any one help me

Answer Posted / rachita

This is because you cannot use > operator with Top-N
Analysis.The operator which is used is only < less-then and
<= less-then-equal-to .You can also use = operator but only
for retrieving the top most value .

Is This Answer Correct ?    13 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

1) What is ONE_SIZE_FITS_ALL approach? 2) Explain the Common & Variable Header of DATA FILE? 3) What are the Drawbacks to using OMF DB? and the Advantages? 4) List out the Advantages of Undo T.spaces over the Undo SEGMENT? 5) Difference between the Temporary tablespace with TEMPFILE and the Tablespace with TEMPORARY Keyword? 6) What are the situation extents are freeing for reuse.

1600


What is proxy method?

536


How to sort output in descending order in oracle?

566


How can I combine multiple rows into a comma-delimited list in oracle?

573


Why do we use bulk collect in oracle?

564






Why we use bulk collect in oracle?

530


What will be the syntax to find current date and time in format "yyyy-mm-dd"?

563


How would you change old and new values in an insert, delete and update triggers?

538


What are joins, explain all types of joins?

1714


How many types of tables supported by oracle?

573


What are the differences between date and timestamp in oracle?

549


How to import one table back from a dump file?

585


Explain joins in oracle?

557


Can we convert a date to char in oracle and if so, what would be the syntax?

546


How to work with data objects interactively?

548