How to retrive the records with in the range

hi,
I want to read the records from the table with in the date range.
for example select empID,empName from EmpTable where stardat to lastdate
please somebody help me...
thanx in advance
cinux

hi,
I want to read the records from the table with in the
date range.
for example select empID,empName from EmpTable where
stardat to lastdate
please somebody help me...
thanx in advance
cinuxhi ,
Oracle provides BETWEEN ..AND.... operator for such requirement.
SQL> select empno,ename,hiredate from emp where hiredate between to_date('03-dec-80','DD-MON-RR') and sysdate;
EMPNO ENAME HIREDATE
7369 SMITH 17-DEC-80
7499 ALLEN 20-FEB-81
7521 WARD 22-FEB-81
7566 JONES 02-APR-81
7654 MARTIN 28-SEP-81
7698 BLAKE 01-MAY-81
7782 CLARK 09-JUN-81
7788 SCOTT 19-APR-87
7839 KING 17-NOV-81
7844 TURNER 08-SEP-81
7876 ADAMS 23-MAY-87
EMPNO ENAME HIREDATE
7900 JAMES 03-DEC-81
7902 FORD 03-DEC-81
7934 MILLER 22-FEB-81
124 johndoe 28-DEC-05
15 rows selected.
Hope this may help you.
Trinath Somanchi,
Hyderabad.

Similar Messages

  • How to extract the record with latest date

    in internal table i a have 10 records, in that for each record only date is changing...so,now the issue is i should extract the record which having the latest date

    try this code -
    data: begin of itab occurs 0,
          name(20),
          add(20),
          bp like sy-datum,
          end of itab.
    itab-name = 'aaa'.
    itab-add = '123'.
    itab-bp = '20061220'.
    APPEND ITAB.
    CLEAR ITAB.
    itab-name = 'bbb'.
    itab-add = '123'.
    itab-bp = '20061219'.
    APPEND ITAB.
    CLEAR ITAB.
    itab-name = 'aaa'.
    itab-add = '123'.
    itab-bp = '20061222'.
    APPEND ITAB.
    clear itab.
    sort itab descending by bp.
    read table itab index 1.
    write: itab.

  • How to create a record based on the name of a file in the file-system?

    Hi,
    With a lot of pictures I want to have a database to gather some information about these pictures.
    First question is how to generate a record based on a file in the file system?
    e.g. the pictures are "c:\fotos\2009\01\disc_001.jpg" to "c:\foto\2009\01\dis_98.jpg" .
    now i want to create records with as one of the attributes the name of the picture (not the picture itself). how to create these records (based on the information of the file-ssytem). i.e. the number of records should be the same as the number of pictures.
    any suggestions?
    any reaction will be appreciated.
    Leo

    Link to Create directory
    http://www.adp-gmbh.ch/ora/sql/create_directory.html
    You can create a list of files in the directory and read the list files from that directory.
    [UTL_FILE Documentation |http://download.oracle.com/docs/cd/B14117_01/appdev.101/b10802/u_file.htm#996728]
    [Solution using Java|http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:439619916584]
    SS

  • How can I reduce the recording time of the webcam?

    How can I reduce the recording time of the webcam?
    thanks
    Alex

    Keep in mind that Logic also has a limit of 8550 quarter notes. So changing the time signature to 4/8 can get longer recording times. So make sure you change this setting along with the song end. See page 93 in the reference manual.
    MBP 1.83 & MDD 1G DP   Mac OS X (10.4.7)   Logic Pro 7.2.2, Motu 828MkII+828, Firebox LC&XT, Tranzport, Unitor8+(3x)AMT-8's

  • I have an apple certified refurbished iPod touch 3rd generatio.  When playing the music with headphones, the music moves from song to song.  When it is on a docking station, it repeats the song.  Any ideas why or how to fix it?

    I have an apple certified refurbished iPod touch 3rd generatio.  When playing the music with headphones, the music moves from song to song.  When it is on a docking station, it repeats the song.  Any ideas why or how to fix it?

    Try:
    - Reset the iOS device. Nothing will be lost
    Reset iOS device: Hold down the On/Off button and the Home button at the same time for at
    least ten seconds, until the Apple logo appears.
    - Unsync all music and resync
    - Reset all settings      
    Go to Settings > General > Reset and tap Reset All Settings.
    All your preferences and settings are reset. Information (such as contacts and calendars) and media (such as songs and videos) aren’t affected.
    - Restore from backup. See:                                 
    iOS: How to back up                                                                
    - Restore to factory settings/new iOS device.             

  • On iTunes when i plug my iphone in, the bar at the bottom with contains the information about the capacity of my iphone, it has a bar called 'other' which has 4GB. I don't know what is taking up that space or how to get rid of it. please help :)

    On iTunes when i plug my iphone in, the bar at the bottom with contains the information about the capacity of my iphone, it has a bar called 'other' which has 4GB. I don't know what is taking up that space or how to get rid of it. please help

    You can reduce the size to normal, which is about 1GB, by restoring the phone.
    Backing Up, updating, and restoring your iPhone and iPod touch software
    The size of this part can increase when something goes wrong during a sync, or some files can't be read anymore by iTunes.

  • Hi,I have recently replaced by hard drive with a ssd. My old hard drive has all my iTunes stuff.i would like to install only iTunes programme on the ssd with all the content on the old hard drive. How do I do it?

    Hi,I have recently replaced by hard drive with a ssd. My old hard drive has all my iTunes stuff.i would like to install only iTunes programme on the ssd with all the content on the old hard drive. How do I do it?

    Install iTunes.
    Once install, hold SHIFT and launch iTunes.
    When prompted, point iTunes to the correct location for the iTunesLibrary.itl file which should be in the iTunes folder under <user>/Music on the old drive.

  • How to call html page with in the flash

    I am new to action script, can some one guide me how to call html page with in the flash. lets say i have movie clip having instance name as "news_feed", I need to disply the html page in this news_feed. kindly help me, thanks alot

    some one tell me, weather it is possible or not ??

  • How can i register column with in the query

    hi all
    how can i register column with in the query?

    Thanks.
    In my business one, the column width was registed.
    But I don't know how can I do it.
    So I try to save the query again after change column width.
    Then the query was opend with changed column width.
    Is it right function?
    Is there any way to register the column width?
    It's very troublesome to change column width every time.
    seiichi

  • How can I extract page with showing the e-sign signatures?

    How can I extract page with showing the e-sign signatures? When I extract pages, the e-sign signatures are all disappear.  Or can I save the documents without verify the signatures?  When I open the documents, it need verify the signatures and then open it now.

    Hi Ada,
    The thing you have to realize is when using Acrobat or Reader to create a digital signature you are signing the whole document (all of the bytes in the document). You are not signing just the page where the signature appearance resides.
    Another thing to realize is the signature appearance (what you see on the page in the signature field) is not the signature itself. The signature proper is a block of hex encoded bytes written into the PDF file and not something you see (unless you open the file in a text editor). What you see on the page is just a graphical representation of the actual signature, but it's not the actual signature.
    When you extract a page (even if it had the signature appearance on it) it is just a sub-set of the signed bytes, and if the signature were to be extracted as well it would be invalid because the bytes in the extracted file would not match the bytes in the signature. Because the signature in the extracted document would always be invalid we just remove it.
    Steve

  • How do you unlock the volme with out the code

    how do you unlock the volme with out the code

    You can't.  If you do not know the volume passcode, your only option is to connect the iPod to your iTunes library and restore it to factory settings. 
    B-rock

  • I'm having trouble recording a bass to go along with a recording I dropped into GB.  I'm using an interface and I can hear the bass line, I've clicked on the 'record' button, but the sound does not record.  What am I missing?

    I have the bass connected to my imac with an interface.
    I can hear the bass and I've clicked on the 'record' button, but the sound does not record.
    Am I missing something ?
    Please advise.
    Mike

    Double check all your audio settings. 
    System Preferences --> Sound --> Input should be set to your audio interface.
    GB --> Preferences --> Audio/MIDI --> Input should be set to your audio interface.
    With your track selected, open the Track Info pane, and select the Edit tab.  Under input make sure that Mono 1 or 2 is selected (which number will depend on which input you plugged your bass cable into).

  • Greetings. Please tell me how much weight iPhone 4s in the box with all the accessories? I am interested in the weight of the smartphone   box   booklets   all the accessories. Thank you.

    Greetings. Please tell me how much weight iPhone 4s in the box with all the accessories? I am interested in the weight of the smartphone   box   booklets   all the accessories. Thank you. (American adapter.)

    I would google the question there doesn't seem to be any agreed weight and you will find plenty of answers all conflicting
    Clearly no-one is coming up with an solution here

  • How do I remove the front housing (the area with all the little holes)?

    I need to remove the housing on the front of my Mac Pro (the area with all the little holes). Something has been spilt down it and I need to get it off so I can clean in all the little holes.

    Changing the Admin Username is WAY too hard.
    Create a new Admin User and password.
    Log out. Log in as the new Admin User you just created.
    Delete the old Admin user. The only way this works is if you created a good Admin user.

  • How to retrieve unique records with more than one column

    I have a table sps_prod as described below -
    POGNAME VARCHAR2(1500)
    INDEX#VERSION VARCHAR2(200)
    POG_MODEL_STATUS VARCHAR2(100)
    POG_LAYOUT_TYPE VARCHAR2(500)
    POG_MARKET_SPECIFIC VARCHAR2(500)
    POG_CONTACT_NUMBER VARCHAR2(100)
    AREA_SUPPORTED VARCHAR2(500)
    POG_COMMENTS VARCHAR2(1500)
    POG_FOOTER_COMMENTS VARCHAR2(1500)
    POG_ELECTRICAL_LIST_1 VARCHAR2(1500)
    POG_ELECTRICAL_LIST_2 VARCHAR2(1500)
    POG_CARPENTRY_1 VARCHAR2(1500)
    POG_CARPENTRY_2 VARCHAR2(1500)
    INSTALLATION_INSTRUCTION_1 VARCHAR2(1500)
    INSTALLATION_INSTRUCTION_2 VARCHAR2(1500)
    FIXTURE_REORDER_NUMBER VARCHAR2(200)
    FIXTURE_ID VARCHAR2(200)
    FIXTURE_NAME VARCHAR2(500)
    FIXTURE_IMAGE VARCHAR2(500)
    PART_REORDER_NUMBER_9 VARCHAR2(500)
    PART_FIXTURE_ID_9 VARCHAR2(500)
    PART_FIXTURE_NAME_9 VARCHAR2(500)
    PART_FIXTURE_IMAGE_9 VARCHAR2(500)
    UPC VARCHAR2(50)
    ITEM_NUMBER VARCHAR2(50)
    DESCRIPTION VARCHAR2(700)
    MERCH_TYPE VARCHAR2(20)
    HEIGHT VARCHAR2(100)
    WIDTH VARCHAR2(100)
    DEPTH VARCHAR2(100)
    CREATE_TS DATE
    There are 4 millions records in it and many with the same combination of POGName,Index#Version,POG_Model_Status,POG_Layout_Type,POG_Market_Specific, POG_Contact_Number and Fixture_Name. How do I retrive records with all the columns above but with unique fixture_name and reorder_number combination. There are no keys defined on the table.
    I guess this is a simple problem but the fact that I am trying to retrieve all the columns is stumbling me.
    Thanks in advance.

    Hi,
    Sanders_2503 wrote:
    ... There are 4 millions records in it and many with the same combination of POGName,Index#Version,POG_Model_Status,POG_Layout_Type,POG_Market_Specific, POG_Contact_Number and Fixture_Name. How do I retrive records with all the columns above but with unique fixture_name and reorder_number combination. I don't see a column called reorder_number. Do you mean fixture_reorder_number or part_reorder_number_9?
    So you want only one row for each distinct combination of fixture_name and some other column (I'll assume that's fixture_reorder_number). Does it matter which row? They won't necessarily have the same values for the other columns.
    The query below returns the one with the first pogname (in sort order):
    WITH     got_r_num     AS
         SELECT  pogname, index#version, pog_model_status, pog_layout_type
         ,     pog_market_specific, pog_contact_number, fixture_name
         ,     ROW_NUMBER () OVER ( PARTITION BY  fixture_name
                                   ,                    fixture_reorder_number
                             ORDER BY        pogname
                           )         AS r_num
         FROM    sps_prod
    SELECT  pogname, index#version, pog_model_status, pog_layout_type
    ,     pog_market_specific, pog_contact_number, fixture_name
    FROM     got_r_num
    WHERE     r_num     = 1
    ;If there happens to be a tie (that is, two or more rows with the same fixture_name, fixture_number, and first pogname) then one of the will be chosen arbitrarily.
    Instead of "ORDER BY pogname", you can ORDER BY any other columns or expressions, but you must have an analytic ORDER BY clause. You can make it "ORDER BY NULL" if you really want to pcik an arbitrary row.
    I hope this answers your question.
    If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only), and also post the results you want from that data (or a couple of examples of acceptable results).
    Explain, using specific examples, how you get those results from that data.
    Always say which version of Oracle you're using.

Maybe you are looking for

  • How do you add a black segment at the end of a clip

    I would like to add a black segment at the end of my movie to lay my credits over? How is this done? Thanks

  • T2 ULTRA DUAL WALKMEN ISSUES

    HI ALL,    I bought sony ultra t2 dual one month back, frequently am getting one prob walkmen, that is " when  walkmen is running some times suddenly sound was stoping but walkmen is running , in that time i tried to stop that song after few minits o

  • Mapping Objects to Relational Databases

    Hi, I do not know if this is the more suitable forum to ask this question, but I am going to try it: I am developing an application with two parts. 1. A server developed in J2SE which is connected to a MySQL database. 2. A client developed in Swing w

  • Safari 7.0 - Opening wrong links on webpages

    Safari Version 7.0 (9537.71) - When I click on links on webpages like Yahoo.com, Safari is opening up a different link from that same webpage than the intended link. This is happening on both an iMac and MacBook Air running the new OS Mavericks.

  • %IGMP_QUERIER-4-SAME_SRC_IP_ADDR

    I am repeatedly getting this message referencing and L2 Trunk Port see below;  %IGMP_QUERIER-4-SAME_SRC_IP_ADDR:An IGMP General Query packet with the same source IP address (172.16.94.1) is received in VLAN 94 on port Gi4/18. any ideas as to whats go