Create Material with reference
Hi all. I have the next requeriment:
On a Z program, a user creates a relation between 2 material in 2 different plants, when the material on the 2nd plant doesn't exist must be created as a copy of the original material. For example:
Original MATNR --> MATERIAL01
Original WERKS --> IN55
Copy MATNR --> MATERIAL02
Copy WERKS --> IN25
In this case, the material MATERIAL02 doesn't exist in the IN25 Plant, so it must be created as a copy of the MATERIAL01.
This could be done manually on MM01 trx and adding the MATERIAL01 value as the reference material, but this needs to be done automatically, and the easiest way to do it is using BAPI.
Does anybody know a BAPI to do this??
Thanx.
Jesus
You can use the BAPI_MATERIAL_SAVEDATA. You will have to get all of the data for the reference material, then swap the material number, then call the BAPI.
Regards,
Rich Heilman
Similar Messages
-
Create material with reference using BAPI
Hi
I need to create material using refrence to another material for all material Views. Can I use BAPI_MATERIAL_SAVEREPLICA.
Which parameter I need to fill for reference materia
Moderator message: please do your own research before asking.
Edited by: Thomas Zloch on Jan 12, 2011 3:18 PMHi Goutam,
You can use the BAPI BAPI_MATERIAL_SAVEDATA, which will create/update the material. You can pass the reference material in the filed BAPI_MARA-PL_REF_MAT. And you can pass reference material for all view like this. -
Create a configurable material with reference to another config material
Hi,
I want to create a configurable material with reference to another configurable material from different system.
Please tell me what data i need to check to see if that material has been created (copied manually) successfully.
Thanks.Hi,
In case of configurable material most important thing is configuration so please check weather the configuration is copied perfectly with all characteristics or not. Similarly check the valuation class and price control is proper or not.
Regards,
Umesh -
Creation of new material with reference to other material
Hi All,
I have requirement where i have to create new selling unit material with reference to the given material.
Now, can any buddy suggest which FM or BADI i have to use to read BOM and ROUTING info of reference material and same to create BOM and ROUTING for new material.
Doing this with BDC after reading data directally from tables is one option, But i am looking for any BADI or Fm which will serve the purpose.
Thanks in Advance,
RahulHi,
... but if you prefer FM, then you can use BAPI_MATERIAL_MAINTAINDATA_RT or BAPI_MATERIAL_SAVEDATA, depending if you are using Retail or not. BDC is usually not possible for all views - which you would need for complete creation.
Regards,
Christian -
SO IDOC inbound create SO with reference to INV or SO #
Hi all,
I have a situation where I will get the inbound SO IDOC, through IDOC_INPUT_ORDERS and create a sales order with reference to a invoice number or another sales order (eg: consignment pick up and consignment fill up).
Except modifying the standard formed BDC in the FM, by adding additional screen code into the BDC, is there any other way to do so?
(eg: assign value into certain field in IDOC? Using another IDOC FM?)
Please advice.
Thanks.
Best Regards,
JLHi ,
At a high level, the IDOC processing executes in the following manner:
1. Interpret IDOC header segments and captures organizational, customer master and purchase
order header details. Performs user exits for each segment to process customizations to data
processing.
2. Interprets item level segments and captures item level details like material information. Again, it
performs user exits for each segment.
3. Sums up the order data and determines the posting criterion viz. creating order with reference
etc.
4. Builds up batch data communication sequence (BDC) with respect to the required screen
sequence of posting a sales order.
5. While building up the BDC data, system performs user exit to process customizations to BDC
data.
6. Calls transactions VA01 using the BDC data.
7. If the processing fails, an appropriate workitem is generated for workflow processing.
User Exit - ZXVEDU03
This user exit will be performed after each segment read in the IDOC processing function module. Exit is called during the perform interpret_idoc_orders in the idoc processing function module. The exit is executed before the BDC data building process and it is here where the invoice number would be retrieved into a variable from segment E1EDK02.
IF SEGMENT-SEGNAM = 'E1EDK02'.
IF SEGMENT-SDATA(3) = 'Z43'.
Save the you Number XXXXXXXXXX into a temporary variable.
Endif.
Endif.
User Exit - ZXVEDU04
In the function module IDOC_INPUT_ORDERS, form call_va01_new_orders is performed wherein BDC data is built up for every screen required to post a sales order. User Exit ZXVEDU04 is performed at various stages during the built up of BDC data. It is here in this user exit that a coding needs to be performed to insert BDC data for assigning sales order to the invoice
The BDC data for assign to invoice should be added soon after the BDC data for purchase order type is generated. The following BDC data logic should be coded in the user exit to facilitate assign to invoice
if you give me brief i can help you out more.
if helpful REWARD points
Thank you .
Regards
Ramana -
Bapi to create Invoice with reference to SalesOrder
Hi All,
I want to create Invoice with reference to SalesOrder ,
can anybody help me regarding
--> what is the Bapi to Create Invoice with reference to SalesOrder
--> what are the import parameters
Thanks in Advance
Regards
SrinivasHi Giuseppi,
Thanks to your reply,
i have used BAPI_BILLINGDOC_CREATEMULTIPLE , i have given the following input values in the BILLINGDATAIN
-- salesorg,distrchan,division,doc-type,sold-to,plant,material,doc-number,item-number , when i execute the Bapi , i got the DocNo:0090021983 , but i did not find that DocNo. by executing the Bapi BAPI_BILLINGDOC_GETLIST.
i found the short description for
BAPI_BILLINGDOC_CREATEMULTIPLE -- is for Individual Customer Billing Document, is it the correct Bapi to create invoice
what is the correct Bapi to create invoice based on the salesorder.
RV_INVOICE_CREATE OR GN_INVOICE_CREATE OR BAPI_BILLINGDOC_CREATEMULTIPLE.
Can u specify the import parameters for that Bapi.
Thanks & Regards
Srinivas -
How to create complaints with reference to ECC Billing document (CRM 7.0)
Hi experts!
I use ECC 6.0 and CRM 7.0.
I have to create CRM complaints (ZCLR - CLRP) with reference to ecc billing documents.
I read the following topics and help:
1. How to create complaints with referenceto ECC Billing document
2. Re: How can we transfer billing documents from SAP ERP to CRM 2007?
3. http://help.sap.com/saphelp_crm70/helpdata/en/46/029ba32e675c1ae10000000a1553f6/frameset.htm
Made these settings:
1. Define the Business object type
Goto SPRO>CRM>Transaction>Settings for Complaints>Integration>Trnsaction Referencing>Define Object types for Transaction reference
2. Assign Business Object Types to Transaction Types
Goto SPRO>CRM>Transaction>Settings for Complaints>Integration>Trnsaction Referencing>Assign Business Object Types to Transaction Types
3. Implement a BADI - CRM_COPY_BADI_EXTERN.Check Implementation CRM_COPY_BADI_BILLDO for more information on the coding for referencing the ECC Billing document.
Goto SPRO>CRM>Transaction>Settings for Complaints>Integration>Trnsaction Referencing>BAdI: Create Complaint with Reference to External Transaction.
but still do not know,
1) if I should pre-replicate billing documents into CRM ?
2) Or, the system uses the RFC to find these documents in ECC to create reference?
Please help me.
Best regards Kostya.
Edited by: Kostya Khveshchenik on Oct 20, 2010 2:09 PMnot resolved =(
Edited by: Kostya Khveshchenik on Nov 19, 2010 8:50 AM -
Creating PO with reference to PR
Hi experts,
I am in a strange problem in our present business process
the user need to create PO with reference to PR
but with out using use roles
i have tried with customising settings in IMG -
MM-- Purchasing---PO--
define Screen layout at document level in the i have made mandatory fields (PR at item level (ME21) document type (NB) and field selection (NBF) eventhough it is not woking
please could any body can solve my problem?
reward point will be give for useful answer
regards
rajHai
The problem is simple
The path
Img-> MM-> Purchasing-> Authorization Management
select Define Function authorization for buyers
enter new entries like CH & name it Purchase order
In field selection NBF (Purchase order)
now select the check box i.e reference to Purchase Requisition
& save.
then select
maintaince users
parameters
enter EFB 7 enter Ch (i.e entry entered) & save
if this is useful to you transfer this message to others who are facing the same problem.
Sharing Knowledge is most important
Regards & thanks
Kalwa Pandarinath -
Create Order with reference to Contract header
Hello,
In copy control from Contract to order can you please tell me if it is possible to copy only header data?
Meaning ,when creating Order with reference to contract I would like to copy contract header data only
Thanks,
DaveHi Dave,
You can try this,
Go to VTAA--> Select your copy control of contract to order --> Click at details --> Remove the check box of
Copy item number
Complete refrence
Then double click at "Item" left side --> Select your item category --> Click at details --> Remove the check box of
Copy Schedule lines
Then try to create and revert back with your findings,
Regards,
MT -
How to create PO with reference to Pr through BAPI
Hi everybody
I wanted to create PO with reference to PR through BAPI_PO_CREATE (4.6c), but i found there is no field to set PR info in the parameter. Is the bapi right for this case, or there are other functions?
THANKS FOR ANY ADVICE!
Best regards,
EggHi abappers!
I'm using bapi BAPI_PO_CREATE1 to create PO with reference to one or more PR. I have a problem with document date:
If the delivery date of the PR is lower than creation date of PR, the document date of the PO is the delivery date (lower than sy-datum).
If the delivery date of the PR is the same or higher than creation date of PR, the document date of the PO is the creation date of PR (sy-datum or high).
I'm trying to change this date in poheader-doc_date, but the system ignores me. I'm sure this is the correct variable, because I use it to create other PO's without reference.
Another thing confuses me is that if I create the PO with reference to the same PR from ME21N, the system doesn't allow me to indicate a document date lower than sy-datum.
Thanks in advance,
Jorge -
How to create Vector with reference to Collection
hello experts,
can someone let me know how to create vector with reference to Collection interface.
Collection is an interface. and we cant create an instance of it. i'm not clear of what to pass in that constructor.
Vector v = new Vector (Collection c);
what are the possible objects of 'c'
post some example code please.
thanksEver heard of reading the javadocs?
"Collection is an interface. and we cant create an instance of it." - you don't understand interfaces, then.
// I certainly can create a Collection - here's one
Collection c = new ArrayList();
// Now I'll add some Strings to my Collection.
c.add("foo");
c.add("bar");
c.add("baz");
// Now I'll make a Vector out of it.
Vector v = new Vector(c);% -
Create Customer with reference
Hi,experts
We want to create customer with reference.
Use the t-cd:XD01 and put a customer code at reference area.
But can't copy the company name,Search term 1/2,Street address.
How can I copy that data??
Or can't copy these data??
Regards,
SaekoDear,
For Any Two company, There are not possible to same name, same address. That's why system do not get the company name,Search term 1/2,Street address.
You can enter manually this data at the time of creation of XD01.
Hope it will help you.
Regards,
Sandip -
Create Material With BAPI_MATERIAL_SAVEDATA
Hi,
I New To SAP I'm Trying To Create Material With BAPI_MATERIAL_SAVEDATA . When I Execute The Code I am Getting Message That ' Bytes Transfered' But When I Checking The MARA Table I Cannot Find The Enteries..
*************************************************************CODE*********************************************************************************
TABLES: bapimathead,
bapi_mara,
bapi_marax,
bapiret2.
TYPES: BEGIN OF lsmw_material_master,
matnr TYPE mara-matnr,
mtart TYPE mara-mtart,
mbrsh TYPE mara-mbrsh,
maktx TYPE makt-maktx,
meins TYPE mara-meins,
END OF lsmw_material_master.
DATA: it_master TYPE TABLE OF lsmw_material_master,
wa_master TYPE lsmw_material_master,
it_materialdesc TYPE TABLE OF bapi_makt WITH HEADER LINE,
it_return LIKE bapiret2.
SELECTION-SCREEN: BEGIN OF BLOCK a1 WITH FRAME TITLE text-001.
PARAMETERS: p_file TYPE rlgrap-filename OBLIGATORY.
SELECTION-SCREEN: END OF BLOCK a1.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file.
DATA: it_tab TYPE filetable,
iv_subrc LIKE sy-subrc.
CALL METHOD cl_gui_frontend_services=>file_open_dialog
EXPORTING
window_title = 'Select Source File'
CHANGING
file_table = it_tab
rc = iv_subrc
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
LOOP AT it_tab INTO p_file.
ENDLOOP.
CALL FUNCTION 'UPLOAD'
EXPORTING
filename = p_file
filetype = 'DAT'
TABLES
data_tab = it_master
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
LOOP AT it_master INTO wa_master.
bapimathead-material = wa_master-matnr.
bapimathead-ind_sector = wa_master-mtart.
bapimathead-matl_type = wa_master-mbrsh.
bapimathead-basic_view = 'X'.
bapi_mara-base_uom = wa_master-meins.
bapi_marax-base_uom = 'X'.
it_materialdesc-matl_desc = wa_master-maktx.
APPEND it_materialdesc.
CALL FUNCTION 'BAPI_MATERIAL_SAVEDATA'
EXPORTING
headdata = bapimathead
clientdata = bapi_mara
CLIENTDATAX = bapi_marax
IMPORTING
return = it_return
TABLES
materialdescription = it_materialdesc
ENDLOOP.
IF sy-subrc = 0.
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
* EXPORTING
* WAIT =
* IMPORTING
* RETURN =
* ELSE.
WRITE:/ 'Error'.
* CALL FUNCTION 'BAPI_TRANSACTION_ROLLBACK'
* IMPORTING
* RETURN =
ENDIF.
*************************************************************FILE >>>>>check.text.********************************************************************************
Cooinfl_Fan
E
FERT
FANS
PC
Bathing_Fan
E
FERT
FANS
PCPlease pass following values:
it_materialdesc-matl_desc = wa_master-maktx.
it_materialdesc-langu = 'E'.
it_materialdesc-langu_iso = 'EN'.
APPEND it_materialdesc.
Regards -
Error when creating PO with reference to PR
Hello Expert,
When creating PO with reference to PR I encountered with one error i.e. system is taking into consideration one to one relation of PR line item to PO line item. For example: I have created PR with one line item for XYZ value and with reference to PR line item I am creating one PO but with two line items in PO that means I am splitting PR value into two line items in PO, 1st line item with zero tax and second one is with tax.
So there is one PR line item but in PO I am creating two line items with reference to single PR item. In this case system is giving error saying Item 001 WBS element XXXXXXXXXX budget exceeded. message no: BP604. However if I create single line item in PO then it wont give any error.
Please suggest any customization setting is done for such kind of behavior of the system.
Thanks
ShyamHi,
SAP creates the requisition with item category "U" even in case of cross-company (intercompany) purchase requisition.
When converting it to PO the item category becomes blank - as I tried and I got no error message.
Please check your settings under SPRO > MM > Purchasing > Purchase Order > Define Document Types (V_T161). You will see (if standard settings have not been changed) that NB requisition type with "U" item category is allowed for NB purchase order type with " " (empty) item category.
Regards,
Csaba -
Recently I get a requirement to create new sale order reference from old sale order.
VA01 have a button to do this work,but abap develop have no FM to get the same effect.
Is there have the only way by bdc to resovle, 3q!you can use the Bapi BAPI_SALESORDER_CREATEFROMDAT2 for creating SO with reference. Pass ref_doc in header data.
Regards,
sivaganesh
Maybe you are looking for
-
Digital signatures and view document througt URL
Hello together, We use status document and digital signatures workflow and we canu2019t use URL link to documents which have been approved. In browseru2019s window I see digital signatures information and error :u201DHTTP 404 the web page cannot be f
-
Gah - Fireworks into Dreamweaver help
Ive done it before. What i have is a map of queensland (australia), and on particular sections there are drop down flashy menus that show the names of cities. I have linked all the cities and such to websites, now its a matter of uploading it to drea
-
How to integrate Apache Web Server and Apache Tomcat 4.0 ?
<pre> Hi All, Can anyone give me a detailed description(or url that tells so) of how to install the Apache Web Server, Apache Tomcat Server4.0 and Integrate both of them. Still now I am using Apache Tomcat 4.0 as a standalone application and now I wa
-
Query "LONG" variable using select
Hi, I am trying to fetch the data of the table in which one of the column is of type LONG. And i get the below error: ERROR at line 1: ORA-00932: inconsistent datatypes: expected NUMBER got LONG BINARY I tried this: set long 20000 But of no use. My D
-
Blank Illustrator Swatch Windows?
I just upgraded my iMac to OSX Mountain Lion, and now, when I try to open a swatch window in Illustrator (5.1), the window is blank, like so: This happens with the default swatches as well as the Pantone ones. I've been able to load the same swatches