HOW TO RESTRICT DUPLICATION OF ITEMCODE IN PURCHASE ORDER

Hi to all,
In PO, we can select same item for a single document.
Is there any work around solution to restrict the duplication of item in PO.
Thanks in Advance,
Sagar

hi Istvan Koros,
Thanks for ur reply.
Can u explain me what is "23" (line 6).
line 1 IF @transaction_type IN (N'A', N'U') AND (@Object_type = N'22')
line 2 BEGIN
line 3 declare  @line int
line 4 set @line=-1
line 5 set @line=(SELECT T0.LineNum+1 FROM POR1 T0
line 6  WHERE T0.DocEntry =23
line 7   and exists(select linenum from por1
line 8            where docentry=T0.DocEntry and itemcode=T0.Itemcode
line 9                and linenum<T0.LineNum) )
line 10 If @line<>-1
line 11 begin
line 12 SET @error = 10
line 13 SET @error_message = N'Duplicate item: line '+
line 14  CONVERT(nvarchar(4),@line) + '!'
line 15 end
line 16 END
Which parameter i should pass it the SP.
SAGAR

Similar Messages

  • How To Restrict Users To Only Create Purchase Requisitions with Item Catalog?

    Hi, everyone 
    Please help me, 
    How To Restrict Users To Only Create Purchase Requisitions with Item Catalog? is it possible? 
    Regards,   Manuel

    Hi Steenie Norman
    First click on the text item ---> Tools ---> Property Pallete ---->
    and change the Keyboard State to Local Only also this Depend in your OS
    hope this useful ....
    Regards
    Mohammed

  • How to restrict header text changes in sales order level

    Dear Experts,
    how to restrict header text changes in sales order level change mode
    thanks

    Hello Chandu,
    how to restrict header text changes in sales order level change mode
    In order to restrict changes to Sales Order Header Text, the appropriate User Exit would be USEREXIT_MOVE_FIELD_TO_TVCOM_H. With the help of ABAPer, you can include the simple logic on the basis of Header Text type such that whenever any changes are incurred on the Sales Order header text, updates would be prevented.
    Please try out this approach and let us know your latest observation on this issue.
    Regards,
    Sarthak

  • How to see the ouput of a purchase order on screen??

    Hi all , how to see the output of a purchase order (ME23) on screen?
    Points will be awarded!!!!
    Thanks & Regards
    John

    Hi,
    If any output tye is associated to PO and it is been triggered then User ME9F tocde to view the output.
    To check thise first Use: ME23 and click on Messages, if any outputs are triggered and they are in Yellow status then Use ME9f. Once you execute you will get Outputs in the screen, then choose the output and click on Display Message button. Your output will be displayed on the screen.
    Regards,
    Ashok

  • How to change material component for a Purchase Order?

    How to change material component for a Purchase Order?
    I need FM .
    PLEASE help

    Dear ,
    Create PO with item category L....There in Item detail you will get tab for material.
    There click in component Button, it will take you to the component screen there you can assign and deassign components.
    Hope this helps.
    Regards
    Utsav

  • How to Assigning the number ranges for Purchase Order using EXIT_SAPMM06E_0

    How to Assigning the number ranges for Purchase Order using EXIT_SAPMM06E_001 using Functional Module NUMBER_GET_NEXT explain me ?

    Hi,
    First go thourh the FM import export parameters list.
    Try to create an internal table of type INRI-NRRANGENR for number ranges.
    We can provide the lower and higher values for this table so that what ever PO is created will be with that range.
    Try to create the ncessary ones using this FM.
    In the Exit, EXIT_SAPMM06E_001,
    the Export parameters are-
    EKKO-EBELN- the PO ios created with in that specified range
    Range as INRI-NRRANGENR - Here try to assign the Internal table that was populated in the FM.
    Try to code this in the Include provded and keep Breakpint and check the PO number generated.
    Reply if u need more help on this.
    Reward if helpful.
    Best Wishes,
    Chandralekha

  • How can we print the Stock Transfer Purchase Order

    Hi,
    How can we print the Stock Transfer Purchase Order??
    Because from Transaction ME9L & ME9F, we can print simple PO's like NB, MPR etc..but Stock Transfer PO could not print.
    Plz guide, from where we can do it...

    Messages for PO are set in MN04. For details on how to follow this link:
    Re: Problem with PO output determination MN04
    Once the record is set here you will see the records in ME23n under messages button in header.
    Edited by: Afshad Irani on Apr 30, 2010 10:09 AM

  • How we will maintian Header Text in Purchase Order Mandatory?

    Dear All,
    How we will maintian Header Text in Purchase Order Mandatory?Please suggest a Solution..
    Thanks,
    Raju

    hi
    in standard  it is not posible  u need to use User exit: EXIT_SAPMM06E_012 of enhancement MM06E005. check details with ABAPer
    Vishal...

  • How to integrate price list on a Purchase Order?

    Hi,
    Version : R12.1.3
    I wanted to know how to use price list on a purchase order. I have created one price list but I am not able to use that, how could I use this.
    How to link Price list to the particular supplier.
    Thanks in advance.
    AmolA

    Oracle purchasing now integrates with Advanced Pricing the same way Order Management does.
    You can set qualifiers / modifiers. You can set up volume discounts etc too.
    See http://www.ncoaug.org/NCOAUG%20Training%20Day%20Feb%202009/Sundeep%20Sharma%20-%20Integrating%20Advanced%20Pricing%20with%20Purchasing%20in%20Release12.pdf
    Sandeep Gandhi

  • How to Create inspection that assign to Purchase Order / Material Document

    Dear QM Master,
    I am using QA01 to create inspection lot but can any master tell me , How to Create inspection that assign to Purchase Order / Material Document ?
    Appreciate.
    Thank you.

    Hello,
    When you create an inspection lot manually, you cannot reference an original document (for example, a goods receipt document, an order, or a delivery note).
    In QA01 you can create inspection lot manually for all inspection lot origins except the following:
    10 - Delivery to customer with sales order
    11 - Delivery to customer without sales order
    12 - General delivery
    13 - Repetitive manufacturing
    14 - Plant maintenance
    You can also refer this link
    http://help.sap.com/saphelp_47x200/helpdata/en/2d/3519d8448c11d189420000e829fbbd/frameset.htm
    Please check and revert.
    Regards,
    Priyanka

  • How we enter text for materials in purchase order smartform

    hi guru
    how we enter text for materials in purchase order smartform
    my requirement is create smartform for purchase order.
    in this i have to create item-text, by using which tcode we can give item data
    plz give more expalnation for this plzzzzzzzzz

    Hi,
           You can use read_text function module for readind text of material and store this value in internal table later pass this internal table to smartform will solve your problem.
    otherwise there is direct option for text element property that is include text u can use that also
    Regards
    Gagan

  • Does Anyone know how to add a new partner to purchase order created on VI01/VI02?

    Does Anyone know how to add a new partner to purchase order created on VI01/VI02?
    Please, anyone knows that?
    Regards.
    Rafael.

    Anyone?

  • Urgent - How to change Item category for Open Purchase Order

    Hi Team,
    Lil bit tricky issue.
    My client has asked us to change the existing Item Category values, Combinations, Category Set etc. Its been changed and uploaded successfully.
    The question here is how we need to handle the category for Open Purchase Order. How to update the same.
    Do we need to do manually or any other way ?
    Please advice
    Regarads,
    John

    Hi John,
    This is reallly a tricky issue!
    I guess you cannot change the category of an existing PO's.
    This field will be greyed out once we save the form...there were no profiles/other setups to enable this field.
    For all new PO's since you have changed the new category value that should not be a issue.
    Lets wait for some of our colleuges opinion.
    I guess PO cancel should be the final option if we dont hear any new work arounds.
    Thanks
    -Arif.

  • How to add tab and field in purchase order

    hi friends,
    I have to make changes in the purchase order. i have to add tab and a field in that.
    i know that badi ME_GUI_PO_CUST have to used this.
    can anyone send me the code or documenation fot add a tab and field using this badi or suggest me how to do this.
    if code or documenation is not available then send me the steps if possible.
    my mail id is [email protected]
                        [email protected]
    hitesh kumar

    Hi,
         1. Double-click on your implementation class
    2. Click on Attributes tab
    3. Add attribute SUBSCREEN1 with level Constant, visibility Public, type MEPO_NAME, initial value 'HDRSCREEN1'.
    please go thourhg the below link .... in this the steps are there and the some of the standard Enchancements also there.
    http://wiki.ittoolbox.com/index.php/HOWTO:Implement_a_screen_exit_to_a_standard_SAP_transaction
    See this treads :
    ME_PROCESS_PO_CUST header n item connection
    Re: BADI IF_EX_ME_PROCESS_PO_CUST~PROCESS_SCHEDULE
    <b>Reward points</b>
    Regards

  • How to activate the Check box in Purchase Order after Goods Receipt

    Hi All,
    How to activate the check box after Goods receipt of Purchase order in Item view (Goods Receipt is completed).
    Where t make the settings in SPRO.
    Regards,
    Shailendra Hadkar

    Hi
    SPRO - SAP IMG- Material management - Inventory management and physical inventory - Goods receipt - create purchase order automatically - activate auto Po creation for movement type.
    Then activate the auto PO creation in Vendor master - Purchasing view
    Check it out.
    Regards,
    raman

Maybe you are looking for