on 03-06-2007 12:20 AM
Hello all
We use SRM server5.5 with classic scenario.
How can I find the vendor role name using vendor code?
Is there a function module?
I tired to find the vendor role name..
So. I found Table: AGR_USERS - AGR NAME (ROLE NAME) using contact person id (AGR_USERS - UNAME).
But.. we only know the vendor code..
Could you tell me how to find the role name with vendor code.
Thank you,
Best regards,
SH.
Hi
<b>You mean to say you are having the Vendor ID (Business Partner ID) in your case.
And based on which, you want to find out the vendor roles.</b>
<u>1) Incase the Vendor is created using SU01 Transaction in the SAP System, you can use BAPI_USER_GET_DETAIL Function module to get all the required details of the system user in one go. Here you need to give the SAP Logon Name (USerID) of the person to the function module, to get all the roles provided in the system for this user.
Incase the vendor iscreated as an ITS USer, use the function module ->
CALL FUNCTION 'BBP_READ_ATTRIBUTES' for the particular user passing the name of the user in the IV_USER Paramater.
2) Incase you want to partner roles, and use only Business Partner ID - Go to Table BUT000 and find the required details.</u>
Or
else use the function modules - BBP_PARTNER_GET_DATA
BAPI_PARTNER_GET_BY_IDNUMBER
BUPA_PARTNER_GET_BY_IDNUMBER
BBP_PARTNER_DETERMINE_ADDRESS
BBP_PARTNER_ADDRESS_GET_COMPL
BBP_PARTNER_FUNCTION_EXISTENCE
BBP_PARTNER_FUNCTION_TEXT
BBP_PARTNER_FUNCTION_TO_TYPE
BBP_PARTNER_FUNC_TEXT_SINGLE
BBP_PARTNER_INHERITANCE
BBP_PARTNER_ON_ITEM_SINGLE_GET
BBP_PARTNER_TYPE_SELECT
BBP_PARTNER_TYPE_TO_FUNCTION
BBP_PDH_GET_PARTNERS_FROM_USER
BBP_PDH_GET_PARTNER_FTYPE_TEXT
BBP_PDH_GET_PARTNER_FUNC_TEXTS
BBP_PDH_PARTNER_GET_FUNC
BBP_PDH_PARTNER_PROD_READ
BBP_PDH_PARTNER_P_PROD_READ
BBP_PDH_PARTNER_TOL_GROUP_GET
Hope this will help.
Please reward suitable points, incase it suits your requirements.
Regards
- Atul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you for your reply.
When buyer issue the PO to vendor, we should check the vendor whether SRM vendor or not.
If vendor in PO document has specific vendor role in SRM, PO data will be transfer to CBO table in SRM.
For this reason, we should know the vendor role name.
But contact person has the vendor role. To validate this logic, we should know the vendor ID.
But I dont know the vendor ID(contact person ID).
I found the BP# using vendor code (BUT050 PARTNER1)
How can I find out the contact person ID using BP#?
Hi
<i>Central Person is the Contact person in this case.</i>
<b>Use either of the the following function modules -></b>
<u>BP_CENTRALPERSON_GET
HR_CENTRALPERSON_GET
CRM_CENTRALPERSON_GET</u>
<b>Here is the sample code</b>
CALL FUNCTION 'BP_CENTRALPERSON_GET'
EXPORTING
iv_person_id = marked_tab-person_id
IMPORTING
ev_bu_partner_guid = lv_employee_guid
ev_username = lv_bname
EXCEPTIONS
no_central_person = 1
no_business_partner = 2
no_id = 3
OTHERS = 4.
IF sy-subrc <> 0.
ENDIF.
<b>Also refer to report -> BBP_USER_COMPARE for more details.</b>
Hope this will help.
Please reward suitable points, incase it suits your requirements.
Regards
- Atul
Hi
IV_PERSON_ID is the SAP Username (SAP logon ->UserID - 12 Characters field )
[ Person Number ]
Here is one more sample code.
data : iv_uname like sy-uname value 'ATUL' .
CALL FUNCTION 'BP_CENTRALPERSON_GET'
EXPORTING
IV_USERNAME = iv_username
IMPORTING
EV_BU_PARTNER_GUID = lv_bp_user_guid
EXCEPTIONS
NO_CENTRAL_PERSON = 1
NO_BUSINESS_PARTNER = 2
NO_ID = 3
OTHERS = 4.
IF SY-SUBRC <> 0.
else.
*--- Get Partner guid in partner number
select single * from but000 into ls_but000_user
where partner_guid = lv_bp_user_guid .
if sy-subrc = 0 .
lv_bp_user = ls_but000_user-partner.
endif.
ENDIF.
Hope this will help.
Please reward suitable points, incase it suits your requirements.
Regards
- Atul
Hi,
Have you try BBP_VENDOR_GETLIST?
or
BAPI_CHARACT_GETLIST BAPI for Characteristics - Find Name
BAPI_CREDITOR_GETDETAIL Vendor Details
Regards,
Marcin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.