Display only the first record

I have report in BEx where we want to find the first time a customer ordered Quantity of more than 500 in a data range (For Ex: From April 10 to April 30). In a particluar date range the customer may order more than once (Qty > 500). The catch is we want display only one first time he ordered qty > 500.
Customer    Date         Qty > 500.
ABC         4/21/2005        2,035 CA
          4/22/2005        12,290 CA
          4/23/2005        4,826 CA
          4/26/2005        6,397 CA
          4/27/2005        1,538 CA
          4/28/2005        4,849 CA
XYZ         4/25/2005        2,000 CA
          4/26/2005        12,000 CA
          4/27/2005        4,500 CA
          4/28/2005        6,300 CA
In the output report we want to display the first record for each customer as:
Customer    Date         Qty > 500.
ABC         4/21/2005        2,035 CA
XYZ         4/25/2005        2,000 CA
Your help is really appreciated. Thanks.

jayant,
i think, you could use your date as a condition to filter by in your report... try looking that the properties of your KF and, under Calculations, set the 'Calculate Result as...' to the first value only.
hope this helps - don't forget to give out points. =)
ryan.
ps. i've tried this, and it sort of works - just need a bit more of tweaking around. =)
Message was edited by: Ryan Kristoffer Tan

Similar Messages

  • Char displaying only the first three characters in the cube

    Hi Experts
    I have a char  with lenth 60 and it's active.I am updating this char via the update routine whereby i am reading data from an active table of an ODS as i update in the update rules.
    But surprisingly,once the load is succesful and complete,upon checking the data in the active table it's displayin the way it should be the problem comes in when I view the data on the cube which displays only the first three chars even if the descriptionis a 60 character field.
    Please help

    Hi Herbert,
    Have you checked in the infosource or transfer rules, what is the length of the infoobject, if you are loading the data to PSA, please check there it self, whether it is displaying 60 characters or only 3 characters.
    Thanks
    Sat

  • Choice displays only the first option.

    hi,
    I am having problem with the "Choice" menu i created. It is displaying only the first choice option, though i select other choices...Meaning, it's displaying only "23.0" whatever other values i select...any suggetions?
    Thanks in advance.
    public class equalneutron extends Applet implements MouseListener{
    //        ... (variable declaration)
             Choice distance = new Choice();   
             public void init() {       
               addMouseListener(this);       
               distance.addItem("23Mpc");       
               distance.addItem("60Mpc");       
               distance.addItem("100Mpc");       
               distance.addItem("200Mpc");       
               distance.addItem("500Mpc");       
               distance.addItem("1000Mpc");       
               r_Mpc=distance.getSelectedItem();       
               add(distance, BorderLayout.NORTH);       
               ItemListener il = new ItemListener() {       
                   public void itemStateChanged(ItemEvent ee){                         
                       if(r_Mpc.equals("23Mpc")){               
                           r = 23.0F;           
                      }else if(r_Mpc.equals("60Mpc")){               
                           r = 60.0F;                           
                      }else if(r_Mpc.equals("100Mpc")){               
                           r = 100.0F;           
                      }else if(r_Mpc.equals("200Mpc")){               
                           r = 200.0F;           
                      }else if(r_Mpc.equals("500Mpc")){               
                           r = 500.0F;
                      }else if(r_Mpc.equals("1000Mpc")){
                           r = 1000.0F;
    distance.addItemListener(il);   
    // ...... rest of the code

    it is allways returning 23.0 because tou've initialized r_MPC to the selected value which is 23.0 at the beginning.
    You must reask the selected value in the listener :
    ItemListener il = new ItemListener() {                      
    public void itemStateChanged(ItemEvent ee){
    String selected = distance.getSelectedValue().toString();
    // the rest of your code
    hope it'll help

  • App file sharing: files are displayed only the first time...

    clicking somewhere else and then back to the application that you want to share files are not there any more.
    I've to close and re-open the itunes in order to see them again.
    itunes is running on windows 7 64bit.
    is this a bug ?
    thank you.

    Hi! I have the same, exact problem. The files are displayed only the first time I look at the apps listed under File Sharing. If I look at another app on the list, the files on the one I previously checked are gone when I look at it again. Is there any way to fix this? I have a Lenovo X61s on Windows XP Professional 32 bit.

  • Display only the last record per material in SAP query

    Hi,
    I have created a SAP Query using the quickviewer that is a join between 2 tables (MSEG and MKPF) that consist of material document information and date of posting.
    The results are fine however I would like only the last record per material to be displayed.
    Can anyone tell what do I need to add so for only the last record per material be displayed in the output.
    Thanks,
    Mark

    Hi Mark,
    May be if you use Control Level processing .........I think you will be able to get the result you want. Try displaying as Below,
    LOOP AT XXXXX.
    AT FIRST material.
    ENDAT.
    AT LAST material.
    *...Display what ever you want here. It will display at end of every material.
    ENDAT.
    ENDLOOP.
    Before using sort the table with key material in ascending.
    Hope what I had to say is helpful to you.
    Cheers,
    Raga Suman.

  • Query needs display only the recent record that was updated into BW.

    Hi Gurus,
    I have a question related to query creation.
    I hve one Infoset which was built on top of Opportunities data and Activities data cubes.  Tthey are linked using Opportunity GUID.  And in the query I am displaying the Opportunity ID(from Opportunity cube),  Sales order Number from the Activities data and a keyfigure No of Doc headers from the opportunities cube.  Everything is fine.  I want to display One Opportunity ID and One Activity associated with it.  I mean I want to display only the activity ID which is very recent.  But the query displays all the activity IDs which are associated with the opportunity ID.   We are not using any time characteristics too as the query has to display all the data that is there in the cubeI just want to see the recent activity that has got updated into the cube.  Kindly advice on how to achieve this..
    THanks in Advance
    Mohan Kumar

    Hi mohan,
    try to do some restriction by using  request ID (0requid) and variable 0S_RQMRC (Most current data on 0requid).
    for example a restriction on activiy id by most current request ID.
    hope it helps.

  • How to populate only the first record by default when the page opens?

    Dear Members,
    I am using OAF R12 and my requirement is as follows:-
    When the user opens the custom OAF R12 page, I just want to query the first record from the underlying VO.
    For example, If the table has 10 rows, I just want to query the first row as soon as the page opens.
    I have written the below code:-
    Process Request Method of the CO:-_
    am.invokeMethod("initHeaders");
    Code in AM_
    public void initHeaders()
    HeadersVOImpl hVO = getHeadersVO1();
    hVO.initQueryHeaders();
    Code in VO_
    public void initQueryHeaders()
    executeQuery();
    As it is very clear that with the above code all the records will be queried. I have to add something before the executeQuery() method in the VO to just query the first record.
    Can any one please help me by guiding me what I should add before the executeQuery() method in the VO?
    Many thanks in advance.
    Regards,
    R4S.

    Hello Gyan,
    Many thanks for your reply.
    The below line in your code is throwing incompatible type error:
    OARow row = vo.first();
    Can you please help me.
    Regards,
    R4S

  • How to display only the duplicate records

    Hi friends,
    I have a query that provides me with a set of data,which has some duplicate rows. I require to display only the duplicates.
    This is the result I have:
    card_no cust_no address paymnt_mode
    1234 A123 XYZ CQ
    1234 A234 nmb CC
    9876 B123 mnnjn cc
    5678 A123 XYZ CQ
    5678 A123 XYZ CQ
    7876 Mk89 mku CC
    From the above ,
    I require to display something like this:(Duplicates based on card number alone)
    card_no cust_no address paymnt_mode
    1234 A123 XYZ CQ
    1234 A234 nmb CC
    5678 A123 XYZ CQ
    5678 A123 XYZ CQ
    Please share some ideas,
    Thanks a lot

    with data as
      select 1234 as card_no, 'A123' as cust_no, 'XYZ' as address, 'CQ' as paymnt_mode from dual union all
      select 1234, 'A234', 'nmb', 'CC' from dual union all
      select 9876, 'B123', 'mnnjn', 'cc' from dual union all
      select 5678, 'A123', 'XYZ', 'CQ' from dual union all
      select 5678, 'A123', 'XYZ', 'CQ' from dual union all
      select 7876, 'Mk89', 'mku', 'CC' from dual
    select card_no, cust_no, address, paymnt_mode
    from
        select card_no, cust_no, address, paymnt_mode, count(*) over (partition by card_no) as cardinality
        from data
    where cardinality > 1;
    CARD_NO                CUST_NO ADDRESS PAYMNT_MODE
    1234                   A123    XYZ     CQ         
    1234                   A234    nmb     CC         
    5678                   A123    XYZ     CQ         
    5678                   A123    XYZ     CQ          Change the column list in the partition by clause if you want to check over other columns as well.

  • When using private browsing to view image results in Safari 5.1.3, only the first two rows of results are visible, the following four or so rows display greyed out place holders, and the safe search button is inoperable. Suggestions?

    When using private browsing to view image results in Safari 5.1.3, only the first two rows of results are visible, the following four or so rows display greyed out place holders, the remainder of the results page is blank, and the safe search button is inoperable. When I turn off private browsing and refresh the page, everything works again.
    Anyone else having this problem?

    I have got the same behaviour after the last Safari Update to 5.1.3. It seems that Safari now handles some scripts in a new way. If you debug the Google Website, you will see, that there is some Javascript Error, that seems to prevent to write into local cache. After some searching I wasn't able to finde a solution for this problem, other then disabling Javascript while private browsing to prevent the script loading. You then are able to use Google with the old layout. The option to disable JavaScript can be found in the Menu "Developer", wich has to be enabled in Safari in the options first.
    In my opinion this is a bug that is now occuring, because Apple changed something in private browsing and that has to be fixed by Google now, to run again. Or we will have to wait for 5.1.4, as you can read online Apple will change and bugfix the javascript engine in that version, perhaps this fixes the problem as well. I hope so!
    If anyone is in the developer program perhaps you could test this with the beta of 5.1.4 and tell us if it works.

  • I used a code i got with my moive to download the itunes version and i was watching the itunes extras, but now when i click on "play itunes extras" it plays the audio but the only thing it displays is the first frame (the movie is catching fire)

    i used a code i got with my moive to download the itunes version and i was watching the itunes extras, but now when i click on "play itunes extras" it plays the audio but the only thing it displays is the first frame (the movie is catching fire) i deleted the movie and reinstalled from my icloud backup and it still does the same thing. The actual movie works fine, its just the itunes extras

    Hi there MickeyDresaj,
    You may find the troubleshooting steps in the article below helpful.
    Troubleshooting iTunes for Windows Vista or Windows 7 video playback performance issues
    http://support.apple.com/kb/ts1718
    -Griff W. 

  • Master-Detail only shows the first record of the Master's data

    I have an ADF Master Table, Detail table. I use ExcuteWithParams on the Master Table. When executed from a button (Button has partial submit = true for button, Master Table has PartialTrigger on button, and Detail table has PartialTrigger on Master table and button), it works fine. However, I want to pass the parameters in pageFlowScope variables, and have the ExecuteWithParams invoked upon page load. When I try to do this, the Detail table only shows the first record of the Master's data, no mater what row is clicked on the Master table.
    Master table now has no PartialTrigger, and Detail table has PartialTrigger on Master table. In my pageDef, I used an invoke action as follows:
    <invokeAction Binds="ExecuteWithParams" id="invokeExecuteWithParams"
    Refresh="always"/>
    What am I missing? I am using verion 11.1.1.3. Any help would be much appreciated.
    Thanks,
    Jessica

    Yes, it works when I drag the data control as a master detail without filtering any data. I want the user to be able to set search criteria to filter the data in the master table (For example, only pull back data with a transaction date between :startdate and :enddate). I can get it to work if I execute from an executewithparams button on the page, but not if I want to invoke the executewithparams upon page load with the parameter set by pageflowscope variables.
    Thank you for responding.
    Jessica

  • Some images do not display in browser, iPad Air 2.  When I load a page with several jpgs (one 1920x720, then 8-10 800x800px), only the first few are shown.  Behaviour is similar for Safari and Chrome. Website issue or iPad?

    I have just bought an iPad, partly to check that my websites work OK on mobile devices.   When I load a page with several jpgs (e.g. one 1920x720, then 8-10 800x800px), only the first few are shown.  If I remove the large one, that sometimes fixes the problem. Behaviour is similar for Safari and Chrome. Is this a website issue or iPad?

    Sorry, I didn't make myself clear.  I'm using a new Wordpress theme that is meant to be responsive.  The large image is for a header, than you scroll down to see the rest, one by one.  Some one the pages work OK on my iPad, typically the old ones where the maximum image size was 500 x 500.  It's the new pages and those I've updated that are causing the problem.  On the iPad the large image loads, then a couple of the small ones become visible as I scroll down, but then darkness (rather like my knowledge level).
    Being new to IOS and iPads, I'm trying to work out whether I should be looking here, or amongst the Wordpress stuff for a solution.
    Here's the website with its new theme: http://www.new-zealand-pictures.com/

  • Opening a form and displaying the first record

    Any ideas on what the easiest solution would be to show the first record on a form when the form is opened? I've tried some of the ideas discussed in the FAQ section, but without success!!
    Thanks........GD

    Greg,
    Sorry, but there is no other solutions other than those described in the FAQ. I know that it is not very "user-friendly", but should work.
    Also if you search the forum's archive there were some concrete examples posted.
    Thanks,
    Dmitry

  • Master-Detail Form - only the first detail record is saved in database

    Hello,
    I have created APEX master-detail form with detail tabular form on the same page.
    I tried to enter data to the several detail rows (using Add Row button) and then press Apply Changes button.
    Unfortunately, only the first detail row is being inserted into the database.
    What could be the reason?
    Thanks in advance,
    Erik

    Hi,
    I had a similar problem.
    Problem with addRow(); function in tabular forms - only first line saved
    Maybe it will help to you.
    Regards
    J :D

  • How to edit only the selected record in Oracle forms 6i

    Hi,
    I have a form which has three control blocks.
    First block is for search criteria, The results in the second block are displayed based on the values entered in the first block. Second block is a multi record block.
    Below is my requirement:
    I want to edit the record in the second block, based on the cursor position.
    For EX: If the cursor is placed on the first record, all the fields in the first record should be in the editable mode.
                  If I move the cursor down, the next record should be editable and the previous record should again go back to non editable mode.
    I have tried using :system.cursor_record, but it's applying the editable property to all fields, irrespective of the cursor position.
    Any suggestions would be of great help.
    Thanks
    Deepthi

    Deepthi,
    Why would you need to do this...it seems unnecessary to me because your user can only edit the record they are physically at.  So, if your user is in record 3 he/she can't edit record 5.
    Now, to the specific issue you are having - if you are using the SET_ITEM_PROPERTY() built-in to make a record "Editable" then what you are seeing is expected results.  The SET_ITEM_PROPERTY() built-in affects ALL instances of a specific item.  If you need to set item instance specific properties then you need to use the SET_ITEM_INSTANCE_PROPERTY() built-in.  However, this built-in does not have the same set of properties that it can set.  Take a look at the Forms Help to compare these built-ins.
    If you must make each record editiable as your user navigates through them here is how I would attempt this.  I must reiterate however, I really don't think this is necessary...but I don't know your requirements .
    1.  Create a Forms parameter to caputure the CURRENT and PREVIOUS Record number.
    I prefer a parameter object over a Global because you can't choose the data type of a Global so you have to cast the value to accurately perform any numeric calculations on a Global.
    2.  Create/update When-New-Record-Instance trigger...
    /* Sample When-New-Record-Instance... */
    BEGIN
       :PARAMETER.Prev_Record := :PARAMETER.Curr_Record;
       :PARAMETER.Curr_Record := :SYSTEM.Trigger_Record;
       IF ( :PARAMETER.Prev_Record != :PARAMETER.Curr_Record) THEN
         -- Make the previous record the user was at Non-Editable...
         Set_Item_Instance_Property('YOUR_BLOCK.YOUR_1st_BLOCK_ITEM', INSERT_ALLOWED, PROPERTY_FALSE);
         Set_Item_Instance_Property('YOUR_BLOCK.YOUR_1st_BLOCK_ITEM', UPDATE_ALLOWED, PROPERTY_FALSE);
         -- You MUST do this for each of the items in the row of your multirecord block.  There is no built-in to set the properties
         -- all of the items in a row...
       END IF;
       -- Now make the current record editable...
         Set_Item_Instance_Property('YOUR_BLOCK.YOUR_1st_BLOCK_ITEM', INSERT_ALLOWED, PROPERTY_TRUE);
         Set_Item_Instance_Property('YOUR_BLOCK.YOUR_1st_BLOCK_ITEM', UPDATE_ALLOWED, PROPERTY_TRUE);
         -- You MUST do this for each of the items in the row of your multirecord block.  There is no built-in to set the properties
         -- all of the items in a row...
    END;
    This sample code is untested and it meant to show you the logic, not the actual functioning code.
    Hope this helps.
    Craig...

Maybe you are looking for