Skip to Content
avatar image
Former Member

How to retrieve the Process Instance ID of the subprocess from the main process ID in BPM?

Details :

Implemented in NWDS

Through: BPM,Web Module(API Servlet)

While triggering through API I am unable to retrieve the process Instance ID of the subprocess through the main process ID.

Any suggestions will be appreciated!

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Mar 31, 2017 at 02:40 PM

    Hi,

    I did it this way. Created the reporting data source and Reporting activity in sub-process and mapped process instance attribute to store parent process ID. Through Reporting data source manager API, I queried processes that have this reporting data source with value of parent process.

    For more on using reporting data source API please refer below URL

    https://help.sap.com/doc/javadocs_nw74_sps11/7.4.11/en-US/CE/bpem/com.sap.bpem/index.html

    I used reporting data source identifier like below

    An URI identifying a reporting data source must be formatted as following:

     bpm://bpm.sap.com/reporting-datasource/<DC vendor>/<DC name>/<Name of the reporting data source>

    and method was below,

    Set<URI> search(URI reportingDataSourceId, String reportingFieldName, String term)
    Searches for process instances that persisted data matching the searched term in the given reporting field.

    where parameters passed were

    reportingDataSourceId = URI created above

    reportingFieldName = reporting field of reporting data source created in sub-process

    term = Main process instance id for which sub-process URIs are to be identified.

    Hope this helps !

    Thanks,

    Amit

    Add comment
    10|10000 characters needed characters exceeded

  • Apr 11, 2017 at 01:06 PM

    Hi,

    Refer the below threads,the approaches followed in this can help you to achieve your solution

    https://archive.sap.com/discussions/thread/1546005

    https://archive.sap.com/discussions/thread/3447899

    Regards

    Kiruthika

    Add comment
    10|10000 characters needed characters exceeded