How can I show the fifth elements (f.e.) in a select

I want to display the last elements of a table. For example, the last fifth elements. I have a field called id, and the elements are ordered by the id. I use order by, but the select display me all the elements, not only the fifth last elements.
I don't know how can I display the last id's.
Thanks

Like this?
SQL> select empno
  2       , ename
  3    from emp
  4   order by empno
  5  /
                                 EMPNO ENAME
                                  7369 SMITH
                                  7499 ALLEN
                                  7521 WARD
                                  7566 JONES
                                  7654 MARTIN
                                  7698 BLAKE
                                  7782 CLARK
                                  7788 SCOTT
                                  7839 KING
                                  7844 TURNER
                                  7876 ADAMS
                                  7900 JAMES
                                  7902 FORD
                                  7934 MILLER
14 rijen zijn geselecteerd.
SQL> select empno
  2       , ename
  3    from ( select empno
  4                , ename
  5                , row_number() over (order by empno desc) rn
  6             from emp
  7         )
  8   where rn <= 5
  9   order by empno
10  /
                                 EMPNO ENAME
                                  7844 TURNER
                                  7876 ADAMS
                                  7900 JAMES
                                  7902 FORD
                                  7934 MILLER
5 rijen zijn geselecteerd.Regards,
Rob.

Similar Messages

  • How can I show the chart in forms?

    Dear all:
    I want to create a line chart. I use the chart wizard and it is successful to create the chart. But, it can't show the chart when I run the form. How can I show the chart in form6i?
    Besides, I see a document that refer to 'OG.pll'.
    I can't find the OG.pll in form6i. Do I need 'OG.pll' to show the chart when I run the form? Thank you very much!!

    Hi Carlos,
    You can try to create a code node for check which signature to print.
    In global variable declare a variable ie named g_sign type TDOBNAME.
    Then pass this var to name of graphics &g_sign&
    please check and reply.
    regards,

  • How can i show the first item in the list as selected item

    Aslam o Alikum (Hi)
    Dear All
    How can i show the first item in the list as selected item when user click on the list. Right now when user click the list the list shows the last item in the list as selected or highlighted. Furthermore if the list item have large no of value and a scroll bar along with it then the list scroll to last item when user click it with mouse. I want that when user click the list item with mouse list should show the first item as highlighted.
    Take Care
    Allah Hafiz

    Hi!
    You can set list "initial value" using When-Create-Record trigger.
    I.g.
    :<Block_name>.<list_item_name> := Get_List_Element_Value('<Block_name>.<list_item_name>', 1);

  • How can I show the photos of the person that im calling? now that im using IOS 7 when i want to call someone the photo /imagine does not appear , how can i fix it? iPhone 5, iOS 7

    how can I show the photos of the person that im calling? now that im using IOS 7 when i want to call someone the photo /imagine does not appear , how can i fix it?
    iPhone 5, iOS 7

    jlfcba wrote:
    IOS 7.1.1 doesn't show a "days to sync" parameter anywhere in SETTINGS/Mail,Contacts,Calendars/ACCOUNTS/GMAIL Account/ GMAIL Acccount Info.  There is nothing in iTunes relating to such an option either.  So, it seems I'm back to square one.
    If you have a decent mail provider like Microsoft Hotmail or Outlook.com mail it does.
    If you have Gmail it does not.  Quite right. Gmail is rubbish.

  • How can I limit the number of rows returned by a select stat

    How can I limit the number of rows returned by a select
    statement. I have a query where I return the number of stores
    that are located in a given area.. I only want to return the
    first twenty-five stores. In some instances there may be over
    200 stores in a given location.
    I know is SQL 7 that I can set the pagesize to be 25....
    Anything similiar in Oracle 8i?
    null

    Debbie (guest) wrote:
    : Chad Nale (guest) wrote:
    : : How can I limit the number of rows returned by a select
    : : statement. I have a query where I return the number of
    : stores
    : : that are located in a given area.. I only want to return the
    : : first twenty-five stores. In some instances there may be
    : over
    : : 200 stores in a given location.
    : : I know is SQL 7 that I can set the pagesize to be 25....
    : : Anything similiar in Oracle 8i?
    : If you are in Sql*Plus, you could add the statement
    : WHERE rownum <= 25
    : Used together with an appropriate ORDER BY you
    : could get the first 25 stores.
    Watch out. ROWNUM is run before ORDER BY so this would only
    order the 25 selected
    null

  • For some reason, when I access FINDER I only can see my files alphabetically, by kind, date etc. In can't see the "tree" of the folders. How can I show the files contained in a folder as a group?

    How can I:
    - Display the tree structure of the folders.
    - Display my files grouped by folders

    Do you mean when you do a Save, or when you click on the Finder icon on your Dock?
    If it's the former click on the arrow to the right of the Save to reveal full finder.
    If it's the latter show the Finder Sidebar and choose your Home folder.

  • How can I show the bookmarks toolbar in Firefox 6 all the time?

    The bookmarks toolbar is hidden by default in Firefox 6, and "view bookmarks toolbar" will only show it until a link is clicked or the tab is changed. How can I display the bookmarks toolbar in Firefox 6 all the time?

    On your toolbar area right click an empty space and open Customize.
    Then drag the bookmark icon up to your toolbar area and drop.

  • How can i show the dialog of certificates when tring to sign (like CAPICOM)

    Hi,
    I'm using "Windows-MY","SunMSCAPI" to choose a certificate from the keystore to sign a document.
    1) Can i show a dialog containing the certificates in the key store like in CAPICOM?
    2) To find a solution i 've found this code (CAPICOM + JAVA) her http://www.jensign.com/JavaScience/www/CertContext/CertContext.txt
    when i compile it, "com.ms.com" et "capicom" are missing ??
    Thank You in advance for any help

    nbbbn wrote:
    In the other words how can i call the *"certificate selection dialog box"* from source code?You can't " call the *"certificate selection dialog box"* from source code" as such. What one can do is iterate through the keys and certificates in the keystore and use the results to populate a dialog.
    The problem I have is that you seem to not want to go through the documentation. Most people here will assist when you have problems but they do like to see some effort. If you had read though the JCE tutorial and done a Google search then you would have found out how process the content of a keystore. If at this point you still had a problem then posting the problem code would likely to be profitable but ...
    Best of luck.

  • How can I show the current value of a substitution variable in FR?

    Hello,
    I want to paste the current month in a text box using a substitution variable in my report. How can I use the Curmth sub-var in a text box? Which function would I use to paste the substitution variable. Thank you.
    -- Adi
    Edit:
    The Sub-Var is not used anywhere in the report but it is in the database that the report accesses.
    Edited by: Aditya26 on Apr 12, 2012 8:42 AM

    I think you can only reference items on the actual report.
    It might be easier to pull the subvar into the report (on a hidden column/row) and then you can reference the cell.
    Cheers, Iain

  • How can i change the ROOT ELEMENT name in my ADOBE Form

    Hello All,
    I need to change "data" the Root Element default name to another name.
    Is this possible? How do i do this?
    Thank you all in advance,
    Eran

    Hello Chintan and Otto,
    thank you for your replies...
    Chintan: There is Adobe livecycle designer CE and its a stand alone application :[ designer CE2|http://www.adobe.com/products/livecycle/]
    Otto: I know i can send the xml back and change it in my abap program but i'm talking about stand alone form in a computer with no sap on it.
    The user will fill it and submit it ...
    Thank you all in advance,
    Eran

  • How can I access the sub elements of the Nested Cluster-2

    would like to know the label a sub element of a Nested Cluster. I have included the vi. I am trying to programmetically read the Text label of the data elements in Value N mode cluster (Max , Min Mode). I was looking into the Type descriptor document. It can tell me how many and what type of elements are in the cluster. But it does not gove me Refnum to those objects.
    Let me know if you have an solution to my question."
    Attachments:
    cluster_1.vi ‏24 KB

    Hi
    You need to do a recursion. If the reference you get from the array "controls[]" if of type cluster, then you have to loop through recursively.
    Openg toolkit has variant tools that might be of some help to you (www.openg.org).
    Good luck
    PJM
    Got EasyXML?
    JKI.VIPM.EasyXML.OpenG.LAVA.Builder.blog

  • How can I access the sub elements of the Nested Cluster

    I would like to know the label a sub element of a Nested Cluster. I have included the vi. I am trying to programmetically read the Text label of the data elements in Value N mode cluster (Max , Min Mode). I was looking into the Type descriptor document. It can tell me how many and what type of elements are in the cluster. But it does not gove me Refnum to those objects.
    Let me know if you have an solution to my question.
    Attachments:
    cluster_1.vi ‏24 KB

    I suggest posting this question on the LabVIEW forum. This is the Measurement Studio for Visual Basic forum and there are not nearly as many LabVIEW experts that monitor this forum as the LabVIEW forum.
    - Elton

  • How can I show the Text variable in WAD 7.0

    Hi All,
    How I can show the text variable in WAD 7.0??
    Kinsly suggest me..
    Re

    Hi,
    As far as i know u do not need any special web item to display the text variable as such. have a analysis item in u r WAD and assign query to the same. Ur variables appear as per the configuration u have made in the query designer. WAD has nothing to do.
    Regards

  • How can I show the full path in terminal?

    By default I only see the current folder
    How can I toggle it so that I see the full path instead?
    I say toggle - I'd like to switch on and off
    Thanks
    Omar

    @arthur, awesome! thats better than what i was trying to do!
    i only wanted to get the path so that i could cd to it
    but then i have to add quotes around because of spaces
    the method u suggested escapes all required chars and means i can just type cd and then drag the folder and then press enter
    @barney: super helpful - i need to re-remember my unix commands. lol

  • How can I show the name in the list of new messages rather than the address

    I have noticed something weird in Apple mail. In the list of new messages, the FROM field sometimes shows the email address rather than the name of the sender (even if that sender is in my address book). Because of this, when I search for some users, I can search by name but for others I must search by email address. However, in the FROM field when I actually open the message, the full name is always in the field rather than the email address (if the contact is in my address book at least).
    Here's a screenshot that illustrates what I am talking about.
    http://img94.imageshack.us/img94/8126/applemail.jpg
    (notice that in the message list it says from [email protected] but in the message view below, it says from Tony XXXX
    My question is: Is there any way to display the actual name in the FROM field in the list of new messages rather than the email address, in the same way it is displayed when I actually open the message? I can't seem to find any settings that fix this.

    Yup, no longer an option.
    Leave feedback for Apple about the feature here:  www.apple.com/feedback

Maybe you are looking for

  • Backups on the disk, but can't access via Time Machine

    Time Machine runs without announcing any errors. Browsing the Time Machine drive in Finder, I can see that TM is actually making the backups. But when I enter Time Machine, I can't access any of the backups. This began under Snow Leopard, but not imm

  • How can I convert a PDF file offline?

    needing help converting pdf's offline

  • Scale Photoshop layer using AppleScript

    Obviously, this is a Mac PS issue. I am trying to script scaling a Photoshop layer (a smart object layer) to a specified percentage that I calculate from a layout in InDesign. However, I am stumped on the syntax I should use to actually get the layer

  • What are the important conditions in taxinn procedure

    hi all please tell what are the important condition types which capture excise and other taxes in taxinn procedure for a manufacturing company? and also the procedure to be used for sales from depot and relevant excise conditions? thanks a lot

  • Adobe Premiere Elements 7 crashing

    Okay, I have had Adobe Premiere Elements for about 2 years now. And, although it has had it's problems, now it will not open. It loads up and takes me to the start up page, but every time I try to load a project or start a new one it says: "Abode Pre