Bapi to update order header user status
Hi
Please suggest any FM or BAPI to update header user status or if no user status exist then it will add the User status at header level.
Thanks
Aditya
Hi Aditya,
Object key is nothing but the Order number.
If you are changing the header level data the Object key is ordernumber. Example: 000300001487
IF you want to change the Components or Partners or Operations then we have to specify the line item number along with order number.
Example : if line item 0020 needs to be changed then Object key = 0003000014870020.
Hope this may be useful.
Regards,
Sravanthi
Similar Messages
-
What's the name of FM for getting Sales Order Header / Item Status info
Hello All:
Do you know what's the name of Function Module for getting Sales Order Header / Item Status Overview ? Any sample code will be very much appreciated.
Basically, I am trying to create a Webpage where user can enter the Sales Order document number and will return the Sales Order: Status Overview.
Thanks,
Dipankar BiswasThanks everybody ! Appreciate for your prompt response. I was also looking for some sample code, and I did find some on. And here is one. I still have to try the code, but here is for all your reference:
*& Report ZBAPI_SALESORDER_GETSTATUS *
*& Read and Display the Sales Order Items and Status of the Order *
REPORT zbapi_salesorder_getstatus NO STANDARD PAGE HEADING LINE-SIZE 200 LINE-COUNT 33(3).
TABLES: vbap. "Sales Document Item Data.
DATA: wa_bapireturn TYPE bapireturn,
wa_bapisdstat TYPE bapisdstat,
it_bapisdstat LIKE STANDARD TABLE OF wa_bapisdstat.
TYPES: BEGIN OF ty_mat_name,
matnr TYPE makt-matnr,
maktx TYPE makt-maktx,
END OF ty_mat_name.
DATA: wa_mat_name TYPE ty_mat_name,
it_mat_name LIKE TABLE OF wa_mat_name WITH KEY matnr .
PARAMETERS: p_vbeln LIKE vbap-vbeln DEFAULT 5573.
START-OF-SELECTION.
SELECT matnr maktx FROM makt INTO TABLE it_mat_name.
CALL FUNCTION 'BAPI_SALESORDER_GETSTATUS'
EXPORTING
salesdocument = p_vbeln
IMPORTING
return = wa_bapireturn
TABLES
statusinfo = it_bapisdstat.
IF wa_bapireturn IS INITIAL. " Successful Execution.
WRITE: / 'Document No: ' COLOR 1, 20 'PO Number : ', 40 'Status' , 50 'Delv.Stat',60 'Item No', 80 'Material', 90 'Material Description', 130 'Net Price' COLOR 2.
ULINE.
LOOP AT it_bapisdstat INTO wa_bapisdstat.
WRITE: / wa_bapisdstat-doc_number. " Sales Document Number.
READ TABLE it_mat_name INTO wa_mat_name WITH KEY matnr = wa_bapisdstat-material.
WRITE: /20 wa_bapisdstat-purch_no, " Customer Purchase Order Number
40 wa_bapisdstat-prc_stat_h, " Processing Status
50 wa_bapisdstat-dlv_stat_h, " Delivery Status
60 wa_bapisdstat-itm_number, " Item Number
80 wa_bapisdstat-material, " Material
90 wa_mat_name-maktx, " Material Description
130(10) wa_bapisdstat-net_price. " Net Price
CLEAR wa_bapisdstat.
ENDLOOP.
REFRESH it_bapisdstat[].
ELSE.
WRITE: wa_bapireturn-message.
ENDIF. -
Create APG ( approval granted) status in process order through user status
Dear Gurus,
My business requirement is to create APG ( approval granted) sytem status in process order through user status functionality, if possible.
This needs to be activated while creating process order itself. Any help is greatly appreciated.
Warm Regards,
SatishAs of this date, we have still not implemented a fix, but I did get some information from someone else who has.
I'll post his information here for all to see. Hope you find it helpful.
From: Joe
Yes we managed to do it.
After several false starts and CMOD/projects which suffered because only the default keys (for order number, aufpl etc) were in place and not the actual, we coded up the IN_UPDATE method in the WORKORDER_UPDATE badi. This gives us the final format after the DB save (but before the commit). The update of the STATUS using the SAP std function module was actioned successfully but the status profile was not actually passed through. We assumed that this was because of the update task - so we introduced an INSERT into JSTO instead (a bit naughty I know, but desperate needs etc). If you require anything more let me know.
Best Regards
Joe -
BAPI/FM for setting the user status for the Project definition and WBS elem
Hi,
I have to set the User Status for the Project Definition and the WBS elements in that project.
The User status to be set is the same for the project and wbs elements.
Please let me know if there is any BAPI/FM to set the user status..
Thanks in advance.
Regards
ShivaHi Shkithija,
There is a dump encoutered in the form "PS_FLAG_GET_GLOBAL_FLAGS" for 'chk_precommit_ok' in the "BAPI_PS_PRECOMMIT".
But it is showing SY-SUBRC = 0 when used along with BAPI_TRANSACTION_COMMIT.
May i know what are input parameters we need to pass it to "BAPI_PS_PRECOMMIT".
Do you have any idea.
Please let me know
Regards
vishnu -
Sales order Header Credit status showing as Approved
Hi all,
My User created a Sales order with 200 tones with around 5700 USD but while saving it did not block sales order for credit but the customer was over their credit limit.in FD32 it already exceed 152 % Further orders have blocked with other customer is was blocking
i check in FD32 it showing Cred.limited used 152%
and the sales order header status showing as - Approved
when the sales order status shows as approved
can any one guide me what could be problem
Thanks
RajeshHi
CHeck with the order, see who has changed it
salesorder- goto - environment- click changes and check it for that.
Check on - how it is released
who has changed
take the log and time
if all the congi
config
fine...then check the change log
or go to table CDHDR
Revert if you have further queries. -
BAPI for process order header delivered quantity
Hi,
current requirement is to get the process order quantity with drawn and delivered quantity , when we try using the BAPI
BAPI_PROCORD_GET_DETAIL , it does not have the process order delivered quantity - it has only total quantity for which process order is created .
Is there a way or any standard BAPI/RFC gives the below :
1. Process Order Header Delivered Quantity
2. Process order component's quantity with drawn
Regards,
Madhu KiranHi Madhu Kiran,
BAPI_PROCORD_GET_DETAIL of course has all the required fields:
1. --> check table POSITION, field DELIVERED_QUANTITY
2. --> check table COMPONENT, field WITHDRAWN_QUANTITY
Regards,
Andreas -
Service Order Component User Status
Hello All -
Has anyone successfully tied a user status profile to the component item on the service order? I've added the object type from BS12 and BS02, but I can't find a configuration assignment at the component level. Any help is greatly appreciated!Hi ,
What i get with your query is that you want to know the user status at component level. I mean to say for example if suppose product has come for repair than at each level of service what is the status of the process at user level you want to know that.you can get that into table crmc_status_proc table. this table is UI filter in order to restrict visibility of status management in the CRM business transaction to the necessary functions there.
Entries in the CRMC_STATUS_PROC table control the following:
Which system status should be displayed in the CRM business transaction?
Which of the system statuses used in the CRM business transaction are lifecycle statuses?
Which system statuses may be set manually in the CRM business transaction?
Which system statuses may be deleted manually in the CRM business transaction?
If a system status may be manually set or reset, which business transactions should be used for setting or resetting?
Should the display or maintenance be restricted to specific business object types?
Which of the system statuses used in the CRM business transaction should be displayed in the toolbars for status maintenance?
Visualization of the system status using an icon
thanks
hemant ghiya -
Is the Sales Order Item User Status available in user exit MV45AFZZ
Hello,
Does anyone know if a sales order line item user status is available within user exit MV45AFZZ (USEREXIT_SAVE_DOCUMENT)?
I need to send an email when the status changes from one specific value to another specific value but I don't seem to have access to what the latest value is in this user exit.
I have found a table XTVSTAT which cntains some user status' but it's not clear which status maps to which line item.
If anyone has any suggestion please let me know.
Thanks,
RubyHi,
I do need to access the values as I need to check for a specific change to the user status from value A to value B.
I have already tried debugging the user exit and searching through the available variables but the status information doesn't seem to be available.
I guess I will have to try the output determination route. Can you explain this in a bit more detail please.
Thanks,
Ruby -
Sales Order Header wise status.
Hy expert,
i going to make Sales order Status Reports. It run successfully fetch data form header wise, but it display all so, that is already closed or completed.
i wnt to which Sales order it is pending or partially deliverd.
Please help me regarding this.
Report in ALV.
Please read this code for fetch Data. if u like change pl do.
Thnks
Bhavesh Panchal
baroda
FORM data_retrieval.
SELECT VBELN NETWR KUNNR FROM VBAK INTO (ITAB-VBELN,ITAB-NETWR,ITAB-KUNNR) WHERE VBELN IN VBELN .
SELECT NAME1 FROM KNA1 INTO (ITAB-NAME1) WHERE KUNNR = ITAB-KUNNR .
SELECT BSTKD BSTDK FROM VBKD INTO (ITAB-BSTKD,ITAB-BSTDK) WHERE VBELN = ITAB-VBELN.
SELECT VSNMR_V FROM VBAK INTO (ITAB-VSNMR_V) WHERE VBELN = ITAB-VBELN.
*SELECT EDATU FROM VBEP INTO (ITAB-EDATU) WHERE VBELN = ITAB-VBELN.
SELECT LFSTK FROM VBUK INTO (ITAB-LFSTK) WHERE VBELN = ITAB-VBELN and lfstk not like 'C'.
APPEND ITAB.
ENDSELECT.Hi,
Try this out.
SELECT vbeln auart spart audat netwr
FROM vbak INTO TABLE it_vbak
WHERE spart IN so_spart
AND audat IN so_fkdat
AND auart IN rg_auart
AND vbeln IN so_vbeln.
SELECT vbeln posnr spart werks matnr arktx kwmeng kbmeng abgru pstyv netwr matkl
INTO CORRESPONDING FIELDS OF TABLE it_vbap
FROM vbap
FOR ALL ENTRIES IN it_vbak
WHERE vbeln = it_vbak-vbeln
AND posnr LIKE '%'
AND werks IN so_werks
AND matkl IN so_matkl
AND matnr IN so_matnr .
IF it_vbap IS NOT INITIAL.
"Get all delivery details
SELECT vbelv posnv vbeln posnn vbtyp_n vbtyp_v rfmng matnr " vbfa_j for All Delivery details
FROM vbfa INTO TABLE it_vbfa_j
FOR ALL ENTRIES IN it_vbap
WHERE vbelv = it_vbap-vbeln AND
posnv = it_vbap-posnr AND
vbeln LIKE '%' AND
posnn LIKE '%' AND
vbtyp_n = 'J'.
ENDIF.
LOOP AT it_vbap INTO wa_vbap WHERE abgru EQ space.
"Get cumulative confirmed qty
wa_final-kbmeng = wa_vbap-kbmeng.
READ TABLE it_vbfa_J INTO wa_vbfa_j WITH KEY vbelv = wa_vbpa-vbeln
posnv = wa_vbfa-posnr.
" BINARY SEARCH.
IF sy-subrc = 0.
wa_final-delivery_qty_total = wa_vbfa-rfmng.
ENDIF.
IF wa_final-delivery_qty_total NE wa_final-kbmeng .
wa_final-pending_order = wa_final-kbmeng - wa_final-delivery_qty_total. "(pending order = Order_qty - total delivery qty)
ENDIF.
CLEAR wa_final.
endloop.
Hope this will help.
Thanks,
Archana -
BAPI for PM Notification system/user statuses (given OBJECT_NO)?
Hi guys,
I am using the BAPI_ALM_NOTIF_GET_DETAIL, so in OBJECT_NO field of the exported table NOTIFHEADER_EXPORT it contains the number that later can be used for se16 -> JEST.
My question is if there is a BAPI that can provide me with the User and System statuses (integer and string values) of this PM Notification, given its OBJECT_NO.
Any hints & tips highly appreciated & rewarded with points.
Please consider that I am still a newbie
Best Regards,
LaloI guess it is the workitem I am referring to.
The body of the email in my workflow message is:
Location &WF_BUS2038.LOCATION&
Description: &WF_BUS2038.MAINTENANCEORDER.SHORTTEXT&
Priority:&WF_BUS2038.PRIORITY&
Notification Number: &WF_BUS2038.NUMBER&
Notif. Date:&WF_BUS2038.NOTIFICATIONDATE&
Reported by: &WF_BUS2038.REPORTEDBY&
Priority Type: &WF_BUS2038.PRIORITYTYPE&
The content in the document in my business workplace is as follows:
Location FM-KINP
Description:
Priority:3
Notification Number: 7000568
Notif. Date:30.03.2009
Reported by: MDEMECHA
Priority Type: FC
I will try to to create the sub-object to get the problem type. Thanks. -
Work orders and updating user status (via IW32)
Hello All,
I was given a design to create a program that will retrieve all open work orders. The program needs to check on all the purchase orders for that work order to check if order quantity matches the received quantity and the invoice quantity. If it matches, I will do an IW32 to change the user status to 'AIP' (All Invoices Paid). If there are no invoices or purchase orders, I will again, do an IW32 to change the user status to 'AIP'.
And since this is my first time to work on a PM ticket, I'm not very familiar with the tables being used. I've tried looking for a list of PM tables. One table I got is AUFK (Order Master Data). I searched through the table and it has the fields for Sales Order Number (KDAUF) and Item Number (KDPOS). Is this the Purchase Order related to the work order? Also, is there a way I can see or verify it through a transaction? I tried looking into transaction IW33 but I couldn't find any Purchase Order Number there. Also, how do you know if a work order is open or not? Is there a field that indicates it?
I was thinking if there are any BAPI's I can use to change a work order's user status instead of doing a CALL TRANSACTION 'IW32'? I saw a function module, RFC_CHANGE_PM_ORDER, that does a remote function call to IW32 but this has dialogs. I'd appreciate any input.
Many thanks in advance!
Regards,
KristineHi
You can use the BAPI - BAPI_ALM_ORDER_MAINTAIN to maintain orders.
Given below few order related tables
AUFK -Production order headers
AFIH -Maintenance order header
AUFM -Goods movement for prod. order
AFKO -Order header data PP orders
AFPO -Order item
RESB -Order componenten
AFVC -Order operations
AFVV -Quantities/dates/values in the operation
AFVU -User fields of the operation
AFFL -Work order sequence
AFFH -PRT assignment data for the work order(routing)
JSTO -Status profile
JEST -Object status
AFRU -Order completion confirmations
This may help you.
Thanks & Regards,
Govind. -
Updating the User Status in Sales Order Item
Dear Gurus,
Iam trying to update the User Status on the SO item using STATUS_CHANGE_EXTERN function module and the status is successfully getting updated.
But the problem is if Iam updating the status it has to delete the Purchase Requisition assgined to it, which is not happening.. whereas when Iam manually changing the Status, the PR is getting deleted.. Can anyone suggest some other function module or some other way of doing it other than BDC?
Best Regards,
Sreenivas.Hi ,
I am also need to update the Item user status. Could you please provide me the logic for the FM 'STATUS_CHANGE_EXTERN'. And also let me know the where we need to write the logic in VA01/VA02.
It would be helpful me a lot.
Thanks
Srihari. -
Dear Gurus,
I want to update equipment user status with PM Order Status.
for example, if i close the PM01 - Maintenance Order , equipment user status will be updated "001-Fixed".
how can i update the user status like above example? I have found some user exit (STATTEXT) but it is not working in PM order. Is there any user - exit for this case?
thanks for your help.Mahee,
you are right, i guess my example is not clear for this case. I wrote this basic example for easy understanding.
anyway, i wanna write a scenario, we have 4 user status for equipments. we wanna run with PM order status and good movements. equipments are on our customers so that we can refurbish and fix on the field or our refurbishment center.
1. if equipment is come from customer for refurbishment , equipment status will be updated "001-waiting for refurbishment" with good issue.
2. if equipment is refurbished, (refurbishment)order will be completed so equipment status will be updated " 002- refurbished"
3.if equipment is not refurbished, (scrap) order will be opened for removing equipment's spare so equipment status will be updated " 003- scrap"
4.if equipment's spare is removed, (scrap) order will be closed and equipment status will be updated " 004 - write off"
I hope it will be cleared.
there is a bapi for updating equipment user status"BAPI_EQUI_GETSTATUS" but i don't want bapi because of locking the equipment. which can i use user-exit or badi for this case?
thanks for your help -
To update user status of an operation in Plant maintenance
Hi
I ma trying to update the user status of an operation of an order using function module status_update but it is not working properly. Although the same function module is working fine for updation of user status of order. Can somebody please tell me some other function module to update the user status of operations?
Thanx in Advance.
Richa.Hi Richa,
I have the same requirement like which you had. updating the operation user status in work order.
How did you attend this requirement. Please let me know your solution.
Thanks in advance. -
Hi
can anybody tell me the FM for updating the order operations user status in transaction IW37N.
regards
vijayHi
Check the fun modules for updation of order Status
STATUS_UPDATE_DJEST
STATUS_UPDATE
ALM_ME_PUSH_STATUS_UPDATE
STATUS_OBJECT_UPDATE
STATUS_UPDATE_ON_COMMIT
Reward points for useful Answers
Regards
Anji
Maybe you are looking for
-
Best Buy messed up online mac mini order
I ordred a Apple Mac Mini, an Apple wireless keyboard and an Apple wirless mouse and my order was unavailable for pick up three hours later! I place the order at 5:53 call the store at 6:30 to ask where my order is and they didn't know. after talking
-
I'm trying to find out how to send emails with java - without using the java mail api - i've been told there is a way to do it but i cant seem to find it - any help on this would be gratefully recieved as i'm totally stuck! :(
-
AuthorizationFailure Error while executing the BPEL Process
Hi, We have created BPEL Process with Partner Link, while executing BPEL Process we are facing the following error as <Summary>AuthorisationFailure: User Not Authorised to execute Service. </Summary> We are currently using SOA 10.1.3.0.. Please help
-
Unable to view .wmf thumbnail pictures - Windows 8
Hello, I am unable to view the thumbnail pictures of a Microsoft clipart image on my computer. I have had this problem before and I can't remember where I found a quick little patch/download to fix this problem. Does any one know how to fix this pro
-
Will Premiere Elements 9 edit and save changes to avchd losslessly?
Hi, I want to buy a new premiere elements to replace my old one (vrsn 3), can I upgrade it still or is it too old? Also, will the new premiere elements 9 edit and save changes to avchd files from Panasonic and Canon without losing any quality? I came