Custom  order of priority queue

I am a novice in Java. I intend to use a priority queue which holds objects. The objects have a string and two integers. I have to order the priority queue based on one of the integer.
I write syntax according to my understanding please correct me.
PriorityQueue<Object> pr = new PriorityQueue<Object>();
comparable(){
sort(Object.int2)// this is the place where I am confused
}

Here's an example:
public class Caller
    public static void main(String[] args)
        Flight f1 = new Flight( "java", 2, 34 );
        Flight f2 = new Flight( "java", 2, 3 );
        Flight f3 = new Flight( "java", 2, 4 );
        Flight f4 = new Flight( "java", 2, 64 );
        Flight f5 = new Flight( "java", 2, 22 );
        Flight f6 = new Flight( "java", 2, 12 );
        PriorityQueue pq = new PriorityQueue();
        pq.add(f1);
        pq.add(f2);
        pq.add(f3);
        pq.add(f4);
        pq.add(f5);
        pq.add(f6);
        System.out.println(pq.poll());
        System.out.println(pq.poll());
        System.out.println(pq.poll());
        System.out.println(pq.poll());
        System.out.println(pq.poll());
        System.out.println(pq.poll());
public class Flight implements Comparable
    private String airlinename;
    private int flightnumber;
    private int number;
    public int compareTo(Object o)
        Flight f = (Flight) o;
        return number - f.getNumber();
    public String toString()
        return airlinename + " - " + number;
    public Flight(String airname, int num1, int num2)
        airlinename = airname;
        flightnumber = num1;
        number = num2;
    public String getAirlinename()
        return airlinename;
    public void setAirlinename(String airlinename)
        this.airlinename = airlinename;
    public int getFlightnumber()
        return flightnumber;
    public void setFlightnumber(int flightnumber)
        this.flightnumber = flightnumber;
    public int getNumber()
        return number;
    public void setNumber(int number)
        this.number = number;
}Got it?

Similar Messages

  • [svn] 3497: Changing internal datastructure utilized by the LayoutManager' s priority queue, in order to provide a mechanism for quicker lookup of items being validated with 'ValidateNow/ValidateClient'.

    Revision: 3497
    Author: [email protected]
    Date: 2008-10-06 14:48:38 -0700 (Mon, 06 Oct 2008)
    Log Message:
    Changing internal datastructure utilized by the LayoutManager's priority queue, in order to provide a mechanism for quicker lookup of items being validated with 'ValidateNow/ValidateClient'. Will be keeping a close watch on perf suite results after this change, to ensure we did not inject memory issues.
    Reviewer: Glenn
    QA: No (Keeping watch on Mustella, but cyclone looked good).
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/framework/src/mx/managers/layoutClasses/PriorityQueue. as

  • Priority Queue Ordering

    In the process of using a Priority Queue the question came up about what order elements with equal priority are removed. The two logical orders would be first in, first out, like the standard queue, or first in, last out, like a stack. However, testing the Priority Queue showed that the elements of equal priority were removed in neither order, and moreover, the elements were stored in a neither consistent nor prioritized order. My question is, what causes this situation, is there any way to predict the order in which equally prioritized elements will be removed, and is there any way to force the Priority Queue into removing elements in a first in, first out order without writing my own?

    In the process of using a Priority Queue the question came up ...I don' t know why.The Javadoc clearly specifies that 'ties are broken arbitrarily'.
    My question is, what causes this situationThe fact that it uses a priority heap algorithm, which is where its O(log(n)) performance comes from.
    is there any way to predict the order in which equally prioritized elements will be removedNo.
    and is there any way to force the Priority Queue into removing elements in a first in, first out order without writing my own?Encode insertion time as a minor key of the priority.

  • Priority Queue problem

    Hi Everybody.
    Can anyone tell me in which order elements of priority queue are sorted.
    I have used following code
    class Test{
    PriorityQueue <strings> pq=new PriorityQueue <Strings>();
    pq.add("silpa");
    pq.add("swati");
    pq.add("roopa");
    pq.add("abc");
    System.out.println(pq);
    System.out.println(pq.poll());
    System.out.println(pq.peak());
    The output I got is
    [abc silpa swathi roopa]
    abc
    roopa.
    Can anybody explain why the collection elements are not sorted ?
    I am getting correct output with peek() n poll().According that methods i should get
    [abc roopa silpa swathi ]
    Explain the reason?

    System.out.println(pq);This line prints out the contents of the queue, by implicitly calling pq.toString(), whose behaviour is inherited from AbstractCollection, which therefore has nothing to do with sorting. So you have no valid reason for expecting any particular ordering.

  • [svn] 3539: Updated RadioButtonGroup to account for recent changes to LayoutManager priority queue .

    Revision: 3539
    Author: [email protected]
    Date: 2008-10-09 10:58:31 -0700 (Thu, 09 Oct 2008)
    Log Message:
    Updated RadioButtonGroup to account for recent changes to LayoutManager priority queue. The order that a RadioButtonGroup was traversed was always dependent on what order that the radio buttons properties were validated. Since this assumption no longer holds true, we are now very specific about how the group orders the RadioButtons (breadth-first for consistency with Flex 2 and Flex 3).
    Check-in Tests: Pass
    Mustella Tests: (RadioButton, RadioButtonGroup) Pass
    Reviewer: Glenn
    QA: Yes
    Bugs: SDK-17248
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-17248
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/RadioButtonGroup.as

    Revision: 3539
    Author: [email protected]
    Date: 2008-10-09 10:58:31 -0700 (Thu, 09 Oct 2008)
    Log Message:
    Updated RadioButtonGroup to account for recent changes to LayoutManager priority queue. The order that a RadioButtonGroup was traversed was always dependent on what order that the radio buttons properties were validated. Since this assumption no longer holds true, we are now very specific about how the group orders the RadioButtons (breadth-first for consistency with Flex 2 and Flex 3).
    Check-in Tests: Pass
    Mustella Tests: (RadioButton, RadioButtonGroup) Pass
    Reviewer: Glenn
    QA: Yes
    Bugs: SDK-17248
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-17248
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/framework/src/mx/controls/RadioButtonGroup.as

  • Multiple Priority Queues?

    All,
    I have read that one may configure up to 4 priority queues, not using the Modular QOS CLI (e.g. "priority-list" command, etc).
    For the Modular QOS CLI, PQs are implemented using LLQ ("priority" command), and for this one can only specify a single PQ (though multiple classes may be mapped to this single PQ).
    What I would like to do is to have 2 distinct PQs (as should be possible in the non modular cli case) and also use CBWFQ (e.g. "bandwidth" command) for the rest of the clases. Basically I want to have EF in one PQ, another "special" class in the other PQ (lower priority than EF), and AF classes using CBWFQ.
    Does anyone know of a way to combine the 2 methods (modular and non modular CLI) of configuring LLQ in order to implement such a configuration? I was encouraged to see that heirarchical policies are supported but so far I have not found a way to specify multiple PQs as well as CBWFQ.
    Thanks much!

    There has been alot of discussion on this subject. But it seems that while IOS will allow you to configure multiple priority queues, its not really possible for it to deliver multiple priority queues.
    Which, if you think about it makes sense. A priority queue is just that, it takes priority over all other queues. If you configue 2 priority queues, how would you then then tell the scheduler that these are both priority, but the 2nd is less of a priority?
    One way you can accomplish what you're trying to do:
    1. Create a single "priority" queue for your EF traffic
    2. Use "bandwidth" to guarantee bandwidth to your special class.
    3. Put your AF traffic in class-default and let it "fair-queue".
    Something like this:
    policy-map foo
    class EF
    priority 100
    class Special
    bandwith 50
    class class-default
    fair-queue
    -Geoff

  • How to change Sales Order Delivery Priority rules/parameters.

    In the picture below I am in the Sales Order work Center>New Sales Order. My question pertains to the Delivery Priority selections. I have been looking to find a place to set or change the parameters/rules of these selections but all that I have been able to find within SAP Help Center is a brief description of what each priority means. I have not been able to find an option to change the rules of the delivery priorities. I have looked through the help center using multiple definitions and have used different work centers and overviews to find a lead and definitions but have not come across many leads. What we would like to do is have the delivery priority Urgent to have certain effects like releasing an order automatically if that priority is selected in the New sales order delivery priority.
    Please share any info or leads you may have in finding parameters and/or the ability to change the rules of the options Immediate, Urgent, Normal and Low.

    Dear Hohn,
    If you choose Immediate for the Delivery Priority, the sales order is treated as a rush order and is released to the execution department automatically.
    That is, this order is set to Released automatically in the Customer Demand view of the Outbound Logistics Control work center and immediately appears in the Delivery Control view of the Outbound Logistics work center.
    Rest Urgent, Normal and Low is only for reporting purpose.
    Regards
    Vignesh Ravichandran

  • Priority queue out handling.

    We're testing the reference system shown in the figure below.
    System Description
    Four 2960 switches are used for transport;
    Equipment 1 and Equipment 2 exchange packets for synchronization;
    To reach synchronization  Equipment 1 and 2 must exchange data with a very low jitter.
    2960 Configuration details
    Four our test puprose, we're using 100Mbit/s ports (22 and 23) as trunk.
    In order to obtain minimum jitter We performed these configurations:
    We Enabled QoS;
    We Marked Synchronization packets with CoS 7 and DSCP 63;
    We marked other kind of traffic inserted in different ports) with CoS 0;
    We set "trust DSCP" on trunk ports;
    On the trunk ports we mapped traffic with CoS 7/DSCP 63 (and only this) on output queue 1;
    We enabled the expedite queue (priority-queue out).
    Question
    With these settings we aim at forcing our synchronization packtes to precede other kind of traffic and go from Equipment 1 to Equipment 2 with minimum jitter.
    Unfortunately we experienced  high jitter when both synchronization packets and other traffic are sent through the systems.
    What is wrong in our assumptions or configurations?
    What is the real behaviour of the expedit queue?

    Seems the right config.
    This is the my configuration and it works well:
    #global level
    mls qos srr-queue input priority-queue 2 bandwidth 20
    mls qos srr-queue input cos-map queue 1 threshold 3  0 1 2 3 4
    mls qos srr-queue input cos-map queue 2 threshold 3  5 6 7
    mls qos srr-queue output cos-map queue 1 threshold 3  5 6 7
    mls qos srr-queue output cos-map queue 2 threshold 3  4
    mls qos srr-queue output cos-map queue 3 threshold 3  2 3
    mls qos srr-queue output cos-map queue 4 threshold 3  0 1
    mls qos
    #port level
    mls qos trust dscp
    priority-queue out
    What is your IOS version?
    Can you use the 2960 Gigabit port?
    Regards.

  • Wanted: Flexible Priority Queue

    Given this class
    class Foo {
    private int STATE, VAL;
    // STATEs are unique, VALs are not
    I want a collection C of Foo objects that supports these operations
    in at most O(log n) time.
    (1) boolean C.contains(Object o);
    --> Using STATE as the comparator
    (2) Object C.get(Object o);
    --> Return a reference to the collection object that equals o,
    again, using STATE as the comparator
    (3) Object C.minExtract();
    --> Remove and return the object with the minimum VAL.
    If there is a tie, choose arbitrarily.
    Operations (1) and (2) call for something like a TreeMap.
    But operation (3) wants to treat the collection as a priority queue,
    which is often implemented as a heap data structure -- which I don't
    see in the classes that come with java.
    In fact all the SortedSet and SortedMap collections seem to require
    unique keys, whereas operation (3) wants to keep the collection sorted
    by non-unique VALs.
    Question: are there off-the-shelf classes I can use to efficiently do what
    I want, or do I need to design it from scratch?
    thanks,
    roy

    DragonMan,
    I agree I may have to create a class which manages two data structures. The first, perhaps, a HashSet. but:
    The other a sorted List of some kind, ordered by VAL.The problem here is "what kind"? As I noted, all of java's sorted collections seem to require unique keys, but VAL is not unique. I suppose I could create my own red-balck tree or heap or whatever, but I'd like to see how much mileage I can get out of java first.
    Currently, I'm considering combining STATE and VAL to make a unique key (since STATE already is unique) whose order however, is dominated by the VAL component.
    roy

  • 6500 strict priority queue size ???

    Hi guys,
    Is it possible to adjust the 6500 line cards strict priority queue size? Most cards assign 85% of thebandwdith to the oridinary queues and 15% to the strict priority queue. It seems that it is not possible to adjust the size of the strict priority queue.
    I have a customer who has numerous T1's encapsulated into IP and the gross amount of traffic is about 200Meg, all of which is real time. If I were to mark this as DSCP 46 (COS 5) it would saturate the strict priorty queue leading not only to performance problems on the T1's but would also starve the rest of the traffic on the 1Gig WAN link.
    Any thoughts guys?
    Regards, Steve

    Hi Paresh,
    Thanks for your reply. I think I didn't explain myself properly. There is a bandwidth allocation of memory for each port. The priority queue gets 15%by default. I have so much priority queue traffic that I want to increase this to 25% because all of it is strict priority (its voice after all). If this canot be done then I will be losing packets of voice since the priorty queue will not be able to accomdate the amount of traffic.
    Best regards, Steve

  • Priority Queue add help?

    ok, I'm making a priority queue from a List and I'm trying to figure out how to add to the queue so that the items are stored in the queue in order and this is what I have.
    On the line that starts if(newItem.compareTo... eclipse is giving me a warning:
    Type safety: The method compareTo(Object) belongs to the raw type Comparable. References to generic type Comparable<T> should be parameterized
    And I dont know what that means? will my add method work as planned?
    Also, my List class has a max size (that is private) and I want it so that if the priority queue tries to add over the max size it will throw an exception but the commented out line just causes an error...any ideas?
    Thanks
         public void enqueue(Comparable newItem) throws QueueException
              //if(aList.size() == MAXLIST) throws Exception
              if(aList.size() == 0) aList.add(1, newItem);
              else
                   for(int i = 1; i <= aList.size(); i++)
                        if(newItem.compareTo(aList.get(i)) == -1) aList.add(i, newItem);
         }

    And I dont know what that means? The warning is referring to generics: http://java.sun.com/docs/books/tutorial/extra/generics/index.html

  • Crm_ customer order closing and change

    hi all,
    can anybody know the how  CRM customer order closing?
    and also I wanna to know how can I change the customer order in the CRM. ??

    Hi Mathivana,
    I had faced these issue several time. As per SAP standard logic whenever you saved order in CRM it replicate immediatly in ERP till that time the order will be locked for any further change in CRM to save transaction data intigrity. The lock gets removed once the CSA queue(notification) from ERP update in CRM than unlocked.
    You check the in SMW01 transaction and perform search with order number you will find Bdocs are in Intermediate stage(I can't tell reason as it can be so many reason why Bdocs get stuck) -Select and activate the Bdocs once again if you are lucky and it activated your order till be unlocked.
    Or else user report most common for this issue "CRM_CHECK_DISTRIBUTION_STATUS" pass order number number and document type to unlock distribution than you will be able to change order.
    100 % sure shot answer. Appriciate if points alloted
    Thanks,
    prem

  • External Inventory Feed - Wish to Exclude Customer Order Stock

    We have an hourly inventory job, which writes available inventory to an external file.  Recently, we learned that the report is including material which has already been reserved for future customer orders (see for example in MD04).  We do not have an ABAP programmer on staff so I am posting our existing code below and would appreciate hugely an updated script.
    I've seen references in other searches to MD04 and use of function 'MD_MPS_READ_STOCK_REQMTS' as well as 'BAPI_MATERIAL_STOCK_REQ_LIST', but do not know how to incorporate this into the hourly job.
    As you can see, the report output is being pulled from MARD-LABST, unrestricted, but it needs to also exclude allocated customer order stock.
    Thank you in advance for looking.
    *& Report  ZMM_INVENTORY_FEED*&*&---------------------------------------------------------------------**&*&*&---------------------------------------------------------------------*
    REPORT  zmm_inventory_feed NO STANDARD PAGE HEADING.
    TABLES:mara,marc,mard,mvke.
    *-------------Types Declaration----------------------------------------*TYPES:BEGIN OF ty_file,
          text(500),
          END OF ty_file,
          BEGIN OF ty_mard,
          matnr    TYPE mard-matnr,
          werks    TYPE mard-werks,
          lgort    TYPE mard-lgort,
          labst    TYPE mard-labst,
          mstae    TYPE mara-mstae,
          maktx    TYPE makt-maktx,
          mvgr2    TYPE mvke-mvgr2,
          END OF ty_mard,
          BEGIN OF ty_final,
          supplier TYPE lfa1-lifnr,   "Supplierid
          matnr    TYPE mard-matnr,   "Item no
          labst    TYPE char13,       "Qty
          qtyback  TYPE char13,       "Qtyback
          qtyorder TYPE char13,       "Qtyorder
          itemav   TYPE c,            "Itemavdate
          itemdis  TYPE char13,       "Discount
          desc     TYPE makt-maktx,   "Description
          END OF ty_final.
    *----------Internal Table Declaration---------------------------------*DATA:it_mard   TYPE TABLE OF ty_mard,
         it_final  TYPE TABLE OF ty_final,
         it_file   TYPE TABLE OF ty_file,*----------Work Area Declaration--------------------------------------*
         wa_mard   TYPE ty_mard,
         wa_temp   TYPE ty_mard,
         wa_final  TYPE ty_final,
         wa_file   TYPE ty_file.
    *----------Local variable Declaration---------------------------------*DATA: lv_labst   TYPE char13,
          lv_labst_i TYPE i,
          lv_labst1  TYPE char13,
          lv_labst2  TYPE j_1itaxvar-j_1itaxam1,
          lv_mess    TYPE string.DATA lv_filename TYPE char100.*----------Selection-Screen Declaration-------------------------------*SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
    SELECT-OPTIONS:s_mstae  FOR mara-mstae OBLIGATORY,                     "Material Status
                   s_mvgr2  FOR mvke-mvgr2 OBLIGATORY,                     "Material Group
                   s_matnr  FOR mara-matnr,                                "Material Number
                   s_werks  for mard-werks,
                   s_lgort  FOR mard-lgort.PARAMETERS:    p_per(3) TYPE n DEFAULT 20,                             "Percentage
                   p_appl   TYPE rlgrap-filename DEFAULT '\\Appsrv02\Datadown\DropShip_SAP_Test\'. "File Path
    SELECTION-SCREEN END OF BLOCK b1.*----------End Of Declarations----------------------------------------*
    *AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_appl.*  PERFORM f4_filename.                     "F4 help for file path
    START-OF-SELECTION.
      PERFORM get_data.
      PERFORM process_data.
      PERFORM file_export.*&---------------------------------------------------------------------**&      Form  GET_DATA*&---------------------------------------------------------------------**       text*----------------------------------------------------------------------*FORM get_data .
      SELECT a~matnr
             a~werks
             a~lgort
             a~labst
             b~mstae
             c~maktx
             d~mvgr2 INTO CORRESPONDING FIELDS OF TABLE  it_mard
                           FROM mard AS a
                     INNER JOIN mara AS b
                             ON b~matnr = a~matnr
                     INNER JOIN makt AS c
                             ON c~matnr = a~matnr
                     INNER JOIN mvke AS d
                             ON d~matnr = a~matnr
                          WHERE mstae   in s_mstae              "Exclude Material Status Filteration
                            AND a~werks IN ('1100','1200')        "Plant in 1100 and 1200
                            AND mvgr2   IN s_mvgr2              "Exclude Material group
                            AND a~matnr IN s_matnr
                            and a~werks in s_werks
                            AND a~lgort in s_lgort.
      SORT it_mard BY matnr werks lgort.
      DELETE ADJACENT DUPLICATES FROM it_mard COMPARING matnr werks lgort.ENDFORM.                    " GET_DATA*&---------------------------------------------------------------------**&      Form  PROCESS_DATA*&---------------------------------------------------------------------**       text*----------------------------------------------------------------------*FORM process_data .
    *--------------File Header Information --------------------------------*
      wa_final-supplier    = 'Supplier Id'.
      wa_final-matnr       = 'Item Number'.
      wa_final-labst       = 'Total Qty'.
      wa_final-qtyback     = 'Qty Backordered'.
      wa_final-qtyorder    = 'Qty on Order'.
      wa_final-itemav      = 'Item NextAvdate'.
      wa_final-itemdis     = 'ItemDiscont'.
      wa_final-desc        = 'Description'.
      CONCATENATE  wa_final-supplier
                   wa_final-matnr
                   wa_final-labst
                   wa_final-qtyback
                   wa_final-qtyorder
                   wa_final-itemav
                   wa_final-itemdis
                   wa_final-desc    INTO wa_file
                                    SEPARATED BY ','." RESPECTING BLANKS.
      APPEND wa_file TO it_file.
      CLEAR :wa_final,
             wa_file.*------------------End File Header---------------------------------------*
    *------------------File Item Data----------------------------------------*
      LOOP AT it_mard INTO wa_temp.
        wa_mard = wa_temp.
        MOVE:wa_mard-matnr TO wa_final-matnr,  "Item No
             wa_mard-maktx TO wa_final-desc.   "Description
        IF wa_mard-werks     = '1100'.
          wa_final-supplier  = '6476'.         "Supplierid
        ELSEIF wa_mard-werks = '1200'.
          wa_final-supplier  = '6477'.
        ENDIF.
        IF wa_mard-labst IS NOT INITIAL.
          lv_labst1 = lv_labst1 + wa_mard-labst.
        ENDIF.
        AT END OF werks.
          IF wa_mard-mstae = 'AE'.
            wa_final-itemdis = '0'.        "Item Discontinued
          ELSEIF wa_mard-mstae = 'CM' OR wa_mard-mstae = 'DR'.
            wa_final-itemdis = '1'.
          ENDIF.
          IF lv_labst1 IS NOT INITIAL AND p_per IS NOT INITIAL.
            lv_labst = lv_labst1 * p_per / 100. "Qty
            lv_labst = lv_labst1 - lv_labst.
            IF lv_labst LT 0.                    "If Qty less than Zero Make it as Zero
              lv_labst = 0.
            ENDIF.
          ELSE.
            lv_labst = lv_labst1.
          ENDIF.
          lv_labst2 = lv_labst.                  "Rounding to Nearest Qty
          CALL FUNCTION 'J_1I6_ROUND_TO_NEAREST_AMT'
            EXPORTING
              i_amount = lv_labst2
            IMPORTING
              e_amount = lv_labst2.
          lv_labst_i = lv_labst2.
          lv_labst = lv_labst_i.
          CONDENSE lv_labst.
          CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
            EXPORTING
              input         = wa_final-matnr
           IMPORTING
             OUTPUT        = wa_final-matnr
          CONCATENATE wa_final-supplier
                      wa_final-matnr
                      lv_labst
                      wa_final-qtyback
                      wa_final-qtyorder
                      '          '"'00/00/0000' "wa_final-itemav
                      wa_final-itemdis
                      wa_final-desc INTO wa_file
                                    SEPARATED BY ','." RESPECTING BLANKS.
          APPEND wa_file TO it_file.
          CLEAR:lv_labst1,
                lv_labst,
                lv_labst2,
                wa_file.
        ENDAT.
        CLEAR:wa_mard,
              wa_temp,
              wa_final.
      ENDLOOP.*---------------------------End  File Item data----------------------*ENDFORM.                    " PROCESS_DATA*&---------------------------------------------------------------------**&      Form  FILE_EXPORT*&---------------------------------------------------------------------**       text*----------------------------------------------------------------------*FORM file_export

    What you said is exactly what I want! Very thankful for your help.
    Yes, I have found that in EBEW table that standard price is valuated with preliminary cost estimate because I don't give a sales order cost estimate but I give an sales order stock in the customizing - requirement class. So, I have this question that how the sales order stock is determined.
    In COPA customizing (COprofitability analysismaster datavaluationSet up valuation using material cost estimate), standard cost estimate or sales order cost estimate can be transferred into COPA value fields in our system.
    But, I have still have a question: I found in our system, preliminary cost estimate in the linked production order is determined for valuation of sales order stock in EBEW table. As sap online help says, cost component splits can not be transferred to COPA.
    So, according to SAP online help, I think what you said u201Cu2026..However , when we start thinking about the result of this cost to flow into COPA , this cannot happen as the Inventory was valued with a Preliminary csot estimate. So , the Online help says that it will not be able to transfer Result of Preliminary cost estimate into COPA for transferrring COGS details. System would always require a Standard cost estimate or a Sales order Cost estimate to flow Cost details into COPAu201D is correct.
    But, in our system, cost component can be transferred into COPA!? When I create a sales billing (invoice) with tcode VF01, it can create a profitability analysis document (shown in VF03) which it had a cost component split for that material in the sales order stock valuated with the preliminary cost estimate. Or where is stored for the Make-to-Order materialu2019s cost component split in COPA?
    That is the real point that confused me. Hope you can help me. Thanks very much.

  • Customer order actual activity report

    Dear experts,
    I am using make to order strategy and I have a multilevel BOM structure. I am following some semi-finished products individually for customer order and some for make to stock. I need a report to see the actual activity confirmations for a single customer order including all the activities of semi-finished products in BOM. For your help please.

    Hi Ahmet,
    This is rather a problem of material ledger multi-level settlement than of activity pricing. Material ledger will pick up the actual activity price correctly and will use the difference against the former activvity price as multi-level price difference on the production process. The problem is, if there are multiple outputs coming out of the process, as is resulting of the order combination process, material ledger will by default search for a apportionment structure (for joint production) in the material master of the main (or original) output material. As nothing will be maintained there, all the differences will go to this material.
    You can overcome the situation by a BADI implementation of BADI cost_split. There should be an example implementation in your system (if you have the Mill Products add-on active, as is indicated because you use Mill_oc) that enables to distribute the price differences by quantity of the outputs of a process. If you don't find the example implementation I could provide it to you.
    best regards,
               Udo

  • SAP Tables  for Open Customer Orders and Sales History

    Dear Experts.
    I am looking to get SAP SD related tables for the following,
    1) SAP tables for Open Customer Orders     
    From SAP, I need to get all tables that Contain all open customer orders for products.
    2) Sales History
    From SAP, I need to get all tables that contain the previous month's sales history (shipped customer orders).
    Please Help!!

    hi
    check the following link
    http://www.erpgenie.com/abap/tables_sd.htm
    hope it will help you
    regards,
    sreelatha gullapalli

Maybe you are looking for

  • OSX Mountain Lion download not included on MBPr 15"?

    Hello everybody! I have a Macbook pro retina 15" and just accidently bought mountain lion via appstore beacuse a thought it was free as my macbook was shipped with mountain lion. I was not logged in on my account so the buy button did say the price,

  • Imac g5 won't boot from any Cd/DVD

    Hey, New member here. I have an Imac 20" 1.8 Ghz PowerPC G5, running Mac OS X 10.4.9. My problem is my computer won't boot from from any DVD or Cd, not the original system disc (10.3.5), not from a newer Imac system disc (10.4.7), not from a Disc War

  • Clearing Documents in App's Dock Icon

    When I right click an app's icon in the dock, I get a list of previously opened documents. How do I clear this list?

  • Database export /import

    hi all while i was exporting /importing im geting some of the errors so how to we need to avoiid thata errors .

  • Safari 8 Isn't playing HTML5 by Default - How To Fix?

    An issue I'm having with the new Safari since upgrading to Yosemite.  My browser is no longer playing HTML5 content by default.  I have the "Click-to-Flash" extension enabled and I have HTML5 selected as my default.  YouTube, however, will only play