Service Contract: Copy line item

Scenario: we have Service Contracts and these have line items with contract start date and end date.
Requirement: We want to create a new line item if the existing line items contract end date -- date profile's    
Rewenal period value(say 10 days) equals to today's date and line item's custom field value equals to X.
Question: what are possible ways we can achieve this?
My thought was to use Actions but I am stuck with start condition. Basically I do not know how to create start conditions that involves fields from Contract Line Items and date profile's period.
Please help.

HI,
You can use Action Profile to achieve your requirement. However there is some enhancement invloved in it.
Create an Action profile for the item category of the service contract. Keep the Start condition as Renewal date >= Todays date.
Use processng type as method call for this action definition and create a custom class and method with the logic to copy the line item into a new line. It seems quite possible.
Regards,
PP

Similar Messages

  • Sales order create/change line item with reference to contract - Open quantity not getting deducted for copied line item from the contract

    Hi friends,
    Please provide some valuable inputs for the following scenario:
    When a sales order line item is created(VA01) or changed(VA02) with reference to a Contract the open quantity is deducted in the contract which is a standard functionality. If the referenced line item is copied (custom enhancement to copy line item), then for the copied line item the open quantity is not getting deducted instead ATP quantity i.e. Available-to-promise is deducted.
    Any inputs on how we can fix this functionality i.e. deduct the open quantity from the contract for the copied line item?
    P.S. : Custom enhancement to copy line item is working fine, but open quantity is not getting deducted if the copied line item was referenced to a contract.
    Thanks,
    Sandeep
    Message was edited by: sandeep

    Sandeep,
    Yes, that was my original interpretation.  I was having a hard time believing that someone would ask such a question. 
    I guess, then, that you already know that you will have to add this logic to your enhancement. You should create your specifications and hand them off to a developer; ideally the one who created this enhanced solution in the first place.
    I do not provide advice in these forums about details of enhanced solutions.  Perhaps one of the other members will be more willing to do your work for you.
    Best Regards,
    DB49

  • Copy line items from Master Agreement to SubAgreement

    Dear all,
    As a requirement, we need to create a dummy line item at master agreement and subagreement level to be able to publish them to ERP without need
    to complete line items (they are completed in ERP via a development).
    We have created master agreement templates with a dummy line item but at subagreement level, templates are not available.
    What we are trying to develop is a script on post_create at agreement level to copy line items from Master Agreement to SubAgreement. We are able to get Master Agreement line items and copy them to the SubAgreement, but the subagreement is not created. This is the code we are using:
    import com.sap.odp.api.doccommon.masterdata.ValueListValueIBeanHomeIfc;
    import com.sap.odp.api.doccommon.masterdata.ValueListValueIBeanIfc;
    import com.sap.odp.api.doccommon.masterdata.ValueListTypeIBeanHomeIfc;
    import com.sap.odp.api.doccommon.masterdata.ValueListTypeIBeanIfc;
    import com.sap.eso.api.contracts.ContractIBeanHomeIfc;
    Mst_agreementBean = doc.getParentIBean();
    lineItemCollectionSub = doc.getLineItems();
    lineItemCollection = Mst_agreementBean.getLineItems();
    collectionsize = lineItemCollection.size();
    colln = Mst_agreementBean.getCollectionMetadata("MA_LINEITEMS").get(Mst_agreementBean);
    colln2 = doc.getCollectionMetadata("MA_LINEITEMS").get(doc)
    newProject = Mst_agreementBean.getIBeanHomeIfc().createFromAnother(Mst_agreementBean);
    newMember = colln.get(1);
    //  Get Values Line Item
    assCat = newMember.getAcctAssignCategory();
    actLimP         = newMember.getActualLimitPercent();
    delAdCity       = newMember.getDeliveryAddressCity();
    delAdCount    = newMember.getDeliveryAddressCountryRef();
    delAdDist       = newMember.getDeliveryAddressDistrict();
    //... (all fields included in the script)
    // Create Line
    newMember2 = newMember;
    AgreementHome = IBeanHomeLocator.lookup(session, doc.getObjectReference());
    AgreementHome.upgradeToEdit(doc);
    // Set Values
    newMember2.setAcctAssignCategory(assCat);
    newMember2.setActualLimitPercent(actLimP);
    newMember2.setDeliveryAddressCity(delAdCity);
    newMember2.setDeliveryAddressCountryRef(delAdCount);
    newMember2.setDeliveryAddressDistrict(delAdDist);
    //... (all fields included in the script)
    try{
    colln2.add(newMember2);
    AgreementHome.save(doc);
    AgreementHome.downgradeToView(doc);
    collectionbean = colln2.get(0);
    logInfo("Value of  collectionbeanSub " + collectionbean );
    }catch (ApplicationException e){
    logInfo("Error " + e.getClass() + ". " + e.getMessage());
    When we try to create an Agreement under a Master Agreement (clicking Add on Agreement tab), following error message is shown related to the line in blue:
    Facility=local4;sessionid=4e73bb8e73304d6284816f93f4e04522a7c387b; tenantid=#tenant.ecb#;username=LUGUELL; exception=Sourced file: inline evaluation of: ``// **   import com.sap.odp.api.doccommon.masterdata.ValueListValueIBeanHomeI ... '' : Method Invocation AgreementHome.save : at Line: 164 : in file: inline evaluation of: ``// **    import com.sap.odp.api.doccommon.masterdata.ValueListValueIBeanHomeI ... '' : AgreementHome .save ( doc )
    Target exception: java.lang.NullPointerException: while trying to invoke the method com.sap.eso.contracts.ContractTypeBo.getVendorVisible()
    of a null object returned from com.sap.eso.contracts.ContractCommonBo.getTypeBo()
    ;stacktrace=Sourced file: inline evaluation of: ``// *JLA*    import com.sap.odp.api.doccommon.masterdata.ValueListValueIBeanHomeI ... '' : Method Invocation AgreementHome.save : at Line: 164 : in file: inline evaluation of: ``// *JLA*    import com.sap.odp.api.doccommon.masterdata.ValueListValueIBeanHomeI ... '' : AgreementHome .save ( doc )
    Target exception: java.lang.NullPointerException: while trying to invoke the method com.sap.eso.contracts.ContractTypeBo.getVendorVisible()
    of a null object returned from com.sap.eso.contracts.ContractCommonBo.getTypeBo()
    Any ideas what is causing the error? What are we missing on our code to copy line items?
    Many thanks,
    Marc Romagosa
    Message was edited by: Marc Romagosa de Riba

    We managed to create a line item at VALIDATE script, but not at POST_CREATE. Either it is a bug or it is not possible at POST_CREATE script.

  • Central Contract Distribution - line items creates many contract in the BE

    Hi SRM Gurus,
    We are in SRM 7 ECC 6 Ehp 4 PPS.  Ext Classic.
    First of all, CCTR - Central Contract can't be distributed as per SAP for PPS impl. 
    But we have a workaround. 
    We made snote 1354971 read with 1423994 implemented. Made the process work.
    Means Assign distribution on the item level was enabled and Distribution reached BE.
    But when we have multiple line items in the Central Contract, and we assign distribution, it creates one contract per line item in the Backend which is really absurd.  Which means if you have 100 line items, its creating 100 contracts.  When we do the call-off against this central contract, we have multiple contracts.
    Gurus, Can you guys throw some light on this entire issue.
    with regards,
    Freemind

    We are having nearly exactly your scenario and CCTR works fine with 1 distributed contract containing multiple items. Check if all the items are distributed to the same purchasing org and location. If all is the same, debug BBP_PD_CTR_TRANSFER with your SRM contract GUID to see when and how multiple contracts get created in ECC.

  • How to copy line item details in Service PO from service contract

    Hi Team,
    i am using service contract with account assignment U and when i am creating a PO with reference of contract then in PO at Item Overview is coming data ok, but at item details in services there is not picking data automatically from contract.
    whats wrong in my scenario.

    Hi,
    Please make sure that you follow the following steps:
    1. Enter the contract and item number in the PO item line
    2. Click on the u201CService Selu201D icon to select the required
    services from the contract
    3. In the Pop-up screen, enter the agreement number in the
    corresponding field.
    4. Now select the required services from the contract and
    use the u201CServicesu201D icon or  the F9 key. Now save the purchase
    order with the adopted lines
    Best Regards,
    Arminda Jack

  • How to copy line items from one expense report to the next

    I travel to the same project/destination every week so in PR05, I was able to just copy the previous expense report for the new week and edit the expense values. Now, when I book travel, the air line booking starts a new expense report entry.
    Is there a way to copy the employee-paid expenses to the GetThere-generated trip entry expense report, i.e. just copy the line items from one expense report to another that already exists. I guess that would be a merge function.

    Hi Tom,
    Here are two alternative solutions:
    Alternative 1:
    If you copy the expense report before you book the services (flight, hotel …)
    in GetThere, then the airline or hotel bookings will not start a new expense
    report but will be assigned to the copied expense report.
    Alternative 2:
    This alternative is a bit laborious.
    Shift the start date and end date of the expense
    report  that was automatically created by
    your flight booking for next week (e.g. Calendar Week (CW)  47) to the week after next week (e.g. CW 48).
    Copy the expense report of the previous week (e.g.
    46)
    Afterwards open the expense report that you
    moved to CW 48 and click on the tab strip itinerary
    Now assign the bookings (flight, hotel …) to the
    expense report of CW 47 by clicking on the button assign to existing trip
    Later delete the expense report in CW 48
    Get back to me if you have any questions concerning the alternatives outlined
    above.
    Note:
    These solution alternatives are only available for customes using HTML5 UIs.

  • Service Contract header, line level and party data report.

    Using 11.5.9.
    In Service Contracts Module, trying to create a query that extracts header data, party data (role and name) and the name of the service from the lines/account tab, ie Full Service, Gold Service etc...
    Created query that retrieve Service Contract header and party data, but when I try to join to mtl_system_items_b, I am getting a product description instead of the name of the service. I also include code below this that pulls in the lines from the lines/account tab which captures line 1.1 and has the correct service name. Note this code does not have the header data and party data built into it, but I am willing to modify either piece of code to create the need join and get the data returned.
    SELECT
    distinct (okhb.contract_number)     contract_number,
    nvl(okhb.contract_number_modifier,'-') contract_modifier,
    okhb.sts_code,
    okhb.start_date     start_date,
    okhb.end_date          end_date,
    okprb.rle_code ROLE,
    msib.description,
    (msib.segment1) item_number,
    hp.party_name
    FROM
    hz_party_sites ps,
    hz_party_sites ps9,
    hz_locations l,
    hz_locations l9,
    hz_cust_acct_sites_all ca,
    hz_cust_acct_sites_all ca9,
    hz_cust_site_uses_all cs,
    hz_cust_site_uses_all cs9,
    hz_parties hp,
    hz_parties hp9,
    okc_rules_b orb,
    okc_rules_b orb9,
    okc_rule_groups_b ogb,
    okc_k_headers_b okhb,
    okc_k_party_roles_b okprb,
    okc_k_lines_b oklb,
    ra_customer_Trx_all rcta,
    mtl_system_items_b msib
    WHERE
    PS.LOCATION_ID = L.LOCATION_ID AND
    ps9.location_id = l9.location_id and
    L.CONTENT_SOURCE_TYPE = 'USER_ENTERED' AND
    l9.content_source_type = 'USER_ENTERED' and
    PS.PARTY_SITE_ID = CA.PARTY_SITE_ID AND
    ps9.party_site_id = ca9.party_site_id and
    CA.CUST_ACCT_SITE_ID = CS.CUST_ACCT_SITE_ID and
    ca9.cust_acct_site_id = cs9.cust_acct_site_id and
    ps9.party_id = hp9.party_id and
    ps.party_id = hp.party_id and
    cs.site_use_id=orb.object1_id1 and
    cs9.site_use_id = orb9.object1_id1 and
    orb.jtot_object1_code in ('OKX_SHIPTO'/*,'OKX_BILLTO'*/) and
    orb9.jtot_object1_code = 'OKX_BILLTO' and
    orb.rgp_id = ogb.id and
    orb9.rgp_id = ogb.id and
    okhb.id = okprb.chr_id and
    msib.inventory_item_id = orb.object1_id1 and
    okhb.contract_number = rcta.interface_header_attribute1 and
    nvl(okhb.contract_number_modifier,'-') = nvl(rcta.interface_header_attribute2,0) and
    ogb.chr_id = okhb.id and
    okhb.sts_code = 'ACTIVE' and
    okhb.contract_number in ('VO-7001','VO-7078') and
    okprb.rle_code in ('CUSTOMER','END_USER')
    --oklb.line_number||'.'||oklbs.line_number = '1.1'
    order by okhb.contract_number;
    select
         to_char(oklb.line_number)||'.'||to_char(oklbs.line_number) subline_number,
    okhb.contract_number,
         okhb.sts_code,
    (msi.segment1) item_number,
         msi.description,
         okcis.number_of_items,
    round(months_between(element.date_completed , element.date_start))     billable_days,
         oklbs.start_date          start_date,
         oklbs.end_date          end_date,
         to_date(oklbs.attribute1, 'YYYY/MM/DD HH24:MI:SS')          warranty_start_date,
         to_date(oklbs.attribute2, 'YYYY/MM/DD HH24:MI:SS')          warranty_end_date,
         oklbs.attribute4 sales_order
    from oks_level_elements_v element,
    okc_rules_v rule,     
    okc_rule_groups_v grp,
    oks_bill_cont_lines_v      obcl,
         okc_k_lines_v          oklbs,
         okc_k_items_v               okcis,
         mtl_system_items_vl     msi,
         okc_k_items_v               okci,
         okc_k_lines_v           oklb,
         okc_k_headers_v          okhb,
    OKS_BILL_TRANSACTIONS_V obtrx
    where trunc(element.date_start) = trunc(obcl.date_billed_from) and
    rule.id = element.rul_id and
    rule.rgp_id = grp.id and
    grp.rgp_type = 'KRG' and
    grp.rgd_code = 'SVC_K' and
    grp.cle_id = oklbs.id and
    oklbs.cle_id     = oklb.id      and
         oklbs.lse_id     <> '2'      and
    okhb.sts_code = 'ACTIVE' and
         msi.inventory_item_id = okci.object1_id1 and
         msi.organization_id = 3      and
         okcis.cle_id          = oklbs.id and
         okci.cle_id          = oklb.id and
         obcl.cle_id           = oklb.id      and
         oklb.chr_id           = okhb.id      and
         obcl.btn_id = obtrx.id and
         okhb.contract_number like 'VO-7078' and
    oklb.line_number||'.'||oklbs.line_number = '1.1'
    order by okhb.contract_number, to_number(oklb.line_number), to_number(oklbs.line_number), oklbs.id;
    Code that pulls in the correct description as seen at line level in Service Contracts Module.
    OUTPUT of this query
    CONTRACT_NUMBER     STS_CODE     ITEM_NUMBER     DESCRIPTION
    XX-XXXX     ACTIVE     FULL SERVICE     FULL SERVICE

    I guess you are looking for coverage name. You need to add two more table to join with items like as in
    select inventory_item_id,a.name,a.item_description from mtl_system_Items_b c,okc_k_lines_tl a,okc_k_lines_b b
    where organization_id=<organization_id>
    and contract_item_type_code in ('SERVICE','WARRANTY')
    and a.id=b.id
    and b.chr_id=-1
    and coverage_schedule_id=b.id;
    Thanks
    Nagamohan

  • Service PO sub line items not appearing in PO print out

    Hi,
    Service PO line items under item details are not appearing on print out...
    Where are they stored ..means in which table?
    Regards

    Hi SSingh,
      Has this problem been solved? we have a similar problem here --- after upgrading from 4.6c to ECC6.0, we found that the service PO line items are not being shown in the PO printout.  This happens for items that have been marked 'delivery complete'.
      How do we get the service lines to print out again?  Appreciate any help out there!

  • Copy line item text in all line items

    Hi
    My requirement is during transaction, if long text entered in one line item the same taxt should copy to all line item by default. if user want to chane the same for particular line item, it should be changable.
    Is it possible?. If yes, please revert in detail.
    Regards

    Hi Devi,
    If you put a plus sign in the text field, the system copy the previuos line text into the current field.
    Of course you can change it if you want.
    In addition we did a change in our system so the header text is transfered to the lines text when the line text field is empty.
    Regards
    Ofer

  • Service Contract Usage line Invoice Amount

    Hello All,
    I have created Service contract with a Usagline and Service line. When entered the Counter reading, and run the 'Service Contract Main billing program', i am getting the invoice amont of 0 only. Could you please tell me how can i proceed.
    And also, what is the relation between 'Service Contract Main Billing Program' and 'QP_CUSTOM' (I have to bill the usage line based on my own logic)
    Please help me
    Thanks inadvance,
    Amarnadh

    Did not understand your question, at least completely. The steps you described and the functionality provided is all right.
    Is the question, which one of these two values to choose from or why they are two values in the LOV?
    Thanks
    Nagamohan

  • Unable to copy line item from Sales Order [ZPLV] to new Sales Order [ZPCV]

    I have here a requirement to create a new Sales Order[ZPCV] with reference to the previously created SO[ZPLV].
    I looked in transaction code VTAA, and the configuration for the aboves condition is:
    target sales doc type - ZCPV   from sales doc type - ZPLV
    dataT: 302, 907 and 001 respectively
    copying requirement: 001
    copy item number is checked
    complete reference is checked
    is there something wrong with the configuration?
    please advice!
    thanks,

    Hi
    For those line items you can assign a REASON FOR REJECTION. Automatically the status of those line items will be closed.
    Thanks,
    Ravi
    PS : sorry....please ignore my post.
    Edited by: sankar ravi on May 20, 2008 3:45 PM

  • Problem in adding vales to service contract line item

    I want  the OBJECT ID  field to be filled in  OBJECT LIST tab at item level when ever  a service product is entered in service contract ( new line item) automatically ...
    I tired wiht CRM_ORDERADM_I_MERGE (CRM_ORDERADM_I_BADI) and
    CRM_ORDERADM_I_MERGE(ZCRM_ORDERADM_I_BADI) methods and using fuction module
    CRM_ORDPRP_I_MAINTAIN_OW  but not success yet.
    any help !!
    Thanks ....
    Edited by: aday rao on Sep 15, 2008 3:08 PM

    The way I typically handle organizational service attributes is to have a single amadmin XML file per AM service and in that amadmin file I have two requests, one to assign the service and the second to modify the service attributes. I then run the amadmin command with the -c continue option on the amadmin XML file so the service is always modified with latest settings regardless of whether or not it was assigned for the first time.
    Since your question relates to service attribute modification investigate the SchemaRequests -> AddAttributeSchema amadmin commands. For example, I use the following files to modify the amUserService
    <Requests>
    <!-- <SchemaRequests serviceName="iPlanetAMUserService" SchemaType="User">
    <RemoveAttributeSchema>
    <Attribute name="someoldattribute"/>
    </RemoveAttributeSchema>
    </SchemaRequests> -->
    <SchemaRequests serviceName="iPlanetAMUserService" SchemaType="User">
    <!-- full path or amadmin must run from same directory -->
    <AddAttributeSchema fileName="/opt/SUNWam/custom/amUserAttributes.xml" />
    </SchemaRequests>
    </Requests>
    <Requests>
    <!-- newest addition first, amadmin will quit on error regardless of -c flag -->
    <AttributeSchema name="somenewattribute"
    type="single"
    syntax="string"
    any="display"
    i18nKey="u301">
    </AttributeSchema>
    </Requests>

  • Service entry sheet creation from PO without selecting line item of PO?

    Dear SAPIENTS,
    While creating service entry sheet for one frame work order (PO) i do not want to select line item of PO. I want all the service of PO line item should come automatically in single service entry sheet number.
    At present whenm i enter the PO number its taking line item 10 as default because of this service of that line item is coming and for every line item i have to create different service entry sheet.
    Regards,
    Kaushal Rai

    Hi,
    in ML81N please enter the entry sheet header data, then go to full screen services, push the button for
    "service selection" and after that  a popup appeares for the service selection (SAPLMLSP
    0500). On the bottom of this popup you have the button "complete" = adopt all = F9. If you hit this
    button all of your services within the service specification will be copied into the entry sheet
    at the same time.
    Regards,
    Edit

  • Value contract - Need restrcition of amount in PO for contract line item

    Hello Guru,
    I want to create a single value contract (WK) for multiple years .. say 3 years with target value as 450K USD with three line items for each year of value 150K USD.  I would like that when buyers create a PO system should not allow them to create release purchase order for each line item more than 150 K for the year. Can somebody tell me how to configure that?
    Here is my current config example :
    Contract #ABC - Target value 450 with validity date 1/1/11 until 12/31/13
    Line item 1 - 150 K
    Line item 2 - 150 K
    Line item 3 -  150 K
    Now when I create PO with respect to contract#ABC line item 1 - system allows me to create PO with more than 150 K but gives me error message only if I exceed more than 450 K (because message 06/042 is error in config).
    The requirement is to create a single contract for the vendor. Can somebody help me to figure out the way to restrict PO amount by each year limit by standard or custom configuration?
    Thanks, Sachin
    Edited by: sachindubey on Feb 29, 2012 10:15 PM

    Hi,
    As far as I remember it was simple logic!
    Something like
    Goto EKPO select KONNR ;
    If  KONNR != blank (Not equal to blank)
    Do not allow to change condition type u201CPB00u201D
    Also incorporate addition date check for your need

  • Issue with PO change output - Service line items

    Hi All,
    This is issue with PO change output. We have PO with line item 10, 20 and item 10 has 4 service line items. PO is approved and initial print out is taken.
    Some one goes and makes changes to 1st service line items of PO line item 10.
    A change output gets triggered. When this output is printed, it prints line item 10 details. This is standard functionality as this item is changed. But its printing all the service line items for this PO line item. Consider a case where there are 3000 service lines for a PO item. If I add 1 service item to this PO line item, the change form prints 3001 services for that line item. There were no changes done to first 3000 service line items.
    Currently PO change form takes care of changes at PO line item but it does not take care of changes at service line item level.
    Is there any setting that needs to be done for this so that it only considers the changes at Service line item level also.
    Regards,
    Shahu

    If you're using a standard form, send a message to SAP. Otherwise make a change in the form.

Maybe you are looking for

  • Can't access OneDrive for Business of my SharePoint 2013 running on Azure

    Hi, I have SharePoint running on a Azure virtual machine setup using the scripts included with the VS2013 gallery image (no AD, only NTML). I've opened the end points 80->80 and made sure OneDrive works locally on the machine and I can access SP from

  • How do I connect my macbook pro 5,5 to 24" cinema display

    how can I connect my macbook pro 5,5 to apple 24" cinema display

  • How do I manually fetch synchronised calendar data?

    In my Mail, Contacts, Calendars Settings, under Fetch New Data > Advanced, I have some synchronised calendars set to Fetch, and my setting in Fetch New Data is Manually. I have a similar setting for a mail account (in the same list on the Advanced pa

  • Cannot burn CDs. "Disk recording not found."

    I updated itunes and now it will not burn CDs for me. I have no other software that would interfere with this. I attempted to uninstall and install GEARS drivers after some google searchs and it did nothing. Might not have done that right though. It

  • Super class setClass() error

    I don't understand why I can't set this. Any suggestions? (BTW - what's the code to type so my posting look like code and not text?) package com.sig.cis217.classes.accts.src;                         //     Create package import java.text.NumberFormat