In this blog post i would explain and list out the step by step process on how we can query Business users from SAP Integrated Business Planning system using CPI-DS
There are two types of SOAP services one for reading users and another for creating/updating/deleting.
- Creation : It can be used to integrate with another Identity management system to bring in all the users at one using this method.
- Reading :
- For reporting or using in another identity management system
- For getting the User names against the User IDs and updating back Master data tables in IBP with Additional attributes so that Change tracking can be done. How : In IBP master data tables, whenever we extract data we get information like last changed on and last changed by, last changed by is IBP user ID. with ibp user id we need to go and find each id and see who is the username behind the same. with this extract we can do a look up to user id and get user name and load back to ibp for users visibility for last changed info – user name. This is kind of automation as we can manually also extract from Business users tile in IBP fiori but manually the file needs to be formatted and needs to be done by someone and can have errors.
We need to start with creation of Communication process in SAP IBP below are the steps to be followed
- Create a Communication User: WEBSERVICESUSER in IBP , Password should be the same as for CPI-DS User – WEBSERVICESUSER.
- Create/Edit : Communication System for CPI-DS to have an inbound communication user WEBSERVICESUSER and save it.
- Create a new communication Arrangement for: SAP_COM_0093 and connect it with HCI_CPI System and WEBSERVICESUSER and save, WSDLs will be generated.
- Once the WSDL is created , this can be used further in other systems to get the required data. in below steps i have used utilizing this within CPI-DS system to create a CPI-DS job and output list of users in IBP
- Create CPI Webservices Data Store with Path to WSDL along with User Credentials as WEBSERVICESUSER and same password as in Step 1.
- Import the Web Service Function
- Create job to generate the Users File.:Note: This type of job is basically a consumption of web service and not a web service call, hence web service function here can’t be target and has to be consumed with in the job and output/target is a file of users from IBP. Now CPI tool is designed in a way that it can have only Web services as target and not as source so in order to consume the web services as source, we need a dummy start of the job, so create a job whose source is file format data store and also target is file format data store. Create a dummy static file having one column and one record. Nothing from the file is used in the job, just a dummy start of job is done and web service function is called within and output sent to file using XML transformations.
- Create the job starting with file as source and in first step- transform 1, just take out the column in the file to the right.
- Import the xml transform as transform 2.Then select the web service function we imported in Step 6.
- Dont map anything from the source, do the below mappings on the Web service function
- BusinessPartnerRoleCodeInterval : Map ‘1’ in IntervalBoundaryTypeCode and map ‘BUP003’ in LowerBoundaryTypeCode
- UserIdInterval : Map ‘3’ in IntervalBoundaryTypeCode, map ‘A*’ in LowerBoundaryUserID and map ‘Z*’ in UpperBoundaryUserID
- In Query processing conditions map QueryHitsunlimtedindicator : ‘false’
- iteration rule should be on source transform.
- In Next step – Transform 3 : bring in the web service transform and again add the web service function. map the webservice function to web service function.
- In next step – Transform4 bring in xML transform and map the required fields out. Iteration rule will be as below
- and eventually in next step is target_query map those output columns to target file format.
- When we run the job a file will be created with list of users and columns we mapped per the needs.
Similar process can be followed for creation of users in SAP IBP. Below are the references:
SAP documentation(Read SOAP) : https://api.sap.com/api/QUERYBUSINESSUSERIN/overview
SAP documentation(create SOAP) : https://api.sap.com/api/MANAGEBUSINESSUSERIN/overview