‎2006 Jun 15 5:20 PM
Hi,
I need to know which BAPI to use to update IE02 user status and system status.
Thnks.
‎2006 Jun 15 7:19 PM
Hi Reson,
You can also look into the Where-used-list for the BAPIS thru SE37 txn to see where and how they have been used. It will give you some idea.
Cheers,
Vikram
‎2006 Jun 15 5:22 PM
‎2006 Jun 15 5:26 PM
‎2006 Jun 15 5:35 PM
Hi Reson,
Try following BAPI :
BAPI_EQUI_CHANGE or
BAPI_EQMT_MODIFY.
Cheers,
Vikram
Pls reward for helpful replies!!
‎2006 Jun 15 6:11 PM
Hi Friends,
Thnks for ur replies. I am using bapi's for the first time. Related to the user status and system status updating, can someone please guide me as to where to look in the bapi and how to go about it.
Your help is highly appreciated.
Thnks.
‎2006 Jun 15 6:15 PM
Hi,
Refer the transaction BAPI to find all the BAPI's.
BAPIs. A nice way to work with your data without learning the SAP data model. BAPIs are functions that are "published" by SAP for customer use. They are very well documented and bring less surprises than internal functions. Go to transaction BAPI to get the tree of the functions by functional areas. In addition to simply using them for data extracts or updates you can look into their source code to understand how the data is organized (but this is not an easy task). BAPIs are the first thing to check if you need to update the data (the next thing would probably be BDC - described in Knowledge Corner as well). Using BAPIs for updates can speed up your program significantly (like 100 times!). You can use them to select the data, but of course if you know how to access the database directly, simple select will work faster. Sometimes BAPIs are the only way to get the data, as it is the case with accessing some objects in APO (that are stored only in "Livecache" memory).
Also, refer the following link for the list of BAPI's
http://www.planetsap.com/LIST_ALL_BAPIs.htm
<b>Reward points if it helps.</b>
‎2006 Jun 15 6:25 PM
Hi Reson,
Please check this online document.
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/CABFABAPIREF/CABFABAPIPG.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCMIDAPII/CABFAAPIINTRO.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCFESDE8/BCFESDE8.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCFESDE5/BCFESDE5.pdf
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCFESBGW/BCFESBGW.pdf
Hope this will help to start learning BAPI.
Regards,
Ferry Lianto
Please reward points if helpful.
‎2006 Jun 15 6:31 PM
hi Reason,
Good Site for BAPI's
http://searchsap.techtarget.com/originalContent/0,289142,sid21_gci948835,00.html
Regards,
Santosh
‎2006 Jun 15 6:38 PM
Thnks for the links guys but i am still locked with the fact that i have to use bapi's. if comeone could explain in relation to what i want it wud be easier for me to understand.
Related to the user status and system status updating of IE02, can someone please guide me as to where to look in the bapi BAPI_EQMT_MODIFY OR BAPI_EQUI_CHANGEand how to go about it.
Your help is highly appreciated.
Thnks.
‎2006 Jun 15 6:49 PM
Hi,
You can go transaction code <b>BAPI</b> to browse above BAPIs. There are some documentation as well over there.
Other way, you can go to transaction <b>SE37</b> and enter the above BAPI name and click on diplay.
Sometimes, you can get the documentation by click on Function Module Documentation button.
Have you looked this function module <b>STATUS_CHANGE_FOR_ACTIVITY</b> to change the status?
Hope this will help.
Regards,
Ferry Lianto
Please reward points if helpful.
‎2006 Jun 15 7:19 PM
Hi Reson,
You can also look into the Where-used-list for the BAPIS thru SE37 txn to see where and how they have been used. It will give you some idea.
Cheers,
Vikram
‎2006 Jun 16 5:44 AM
Hi Reson,
If ur requirement is to change the userstatus of the equipment, U can use the FM
STATUS_CHANGE_EXTERN' , followed by
STATUS_UPDATE_DIALOG.
See this Example code.
DATA: lws_estat LIKE tj30t-estat,
lws_objnr LIKE jsto-objnr,
lws_jsto LIKE jsto,
ws_value LIKE equi-equnr,
ws_status LIKE tj30t-txt04,
ws_stsma LIKE tj30t-stsma.
ws_value = '10123150'.
ws_status = 'LI'.
ws_stsma = 'PM_EQ_02'.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = ws_value
IMPORTING
OUTPUT = ws_value.
CONCATENATE 'IE' ws_value INTO lws_objnr.
-
Use this FM if u don't know the value of ws_stsma
CALL FUNCTION 'STATUS_OBJECT_READ'
EXPORTING
objnr = lws_objnr
IMPORTING
e_jsto = lws_jsto
EXCEPTIONS
object_not_found = 1
OTHERS = 2.
In this case use lws_jsto-stsma in place of ws_stsma
-
Get Status code
SELECT SINGLE estat INTO lws_estat
FROM tj30t
WHERE txt04 EQ ws_status "LI
AND spras EQ sy-langu+0(1)
AND stsma EQ ws_stsma.
IF sy-subrc = 0.
CALL FUNCTION 'STATUS_CHANGE_EXTERN'
EXPORTING
client = sy-mandt
objnr = lws_objnr
user_status = lws_estat
EXCEPTIONS
object_not_found = 1
status_inconsistent = 2
status_not_allowed = 3
OTHERS = 4.
IF sy-subrc = 0.
CALL FUNCTION 'STATUS_UPDATE_DIALOG'.
ENDIF.