Hi, John.
Okay, let's try the next scenario.
Create a background processing event (SM64). Create a metachain with event-based start process (Start Process variant -> Direct-scheduling -> Change selection -> After event), select your event and specify parameters for it (maybe you want to have some generic event with process-chain name as parameter). Insert your special process chain right after the start process. This pattern will allow you to run this PC in event-based manner anywhere you want.
Then we had to make some setup for triggering that event. You've described two options.
1. Your initial requirement was not so real-time, and you wanted to run that PC after the DSO had received some record. This looks like every "specific" record will trigger that process chain, so maybe it will be better to create some "queue-like" DSO in order to fill it from multiple sources with some key and "specific record flag" and then run that process chain only once for one load job?
In both ways: add "End routine" in the transformation for that DSO (initial DSO or technical DSO with flags only), add some flag variable in transformation class definition (in global section), check for the specific record during the transformation and set this flag to "true" if such record exists.
Then you should trigger an event to run process chain in case of existence of special record, but you want to do this once for one DTP request. In end routine check if current datapackage is the last one:
select count(*) from RSBKDATAPAKID where REQUID = <current REQUID> and DATAPAKID = <current datapakid> and ISLAST = abap_true.
If this query returns something, then current datapackage is the last, so you should check for "specific record flag" set to true and raise your event:
if sy-dbcnt > 0 and gv_has_special_recs = abap_true. call function 'BP_EVENT_RAISE" exporting eventid = <your event id> eventparm = <your event parameters>. endif.
This will trigger your process chain to run.
2. The second requirement looks like custom real-time replication. There's some special products for BW (ODP, SLT and others) suited for realtime, and you could use them in order to use an existing "wheel" than reinvented (after the replication you could apply the same logic as above).
Anyway, you could use a template described above for ECC system. Schedule a job on ECC side that will check for that specific records in ECC, and if they are found it will raise the same event in your BW via RFC: call function 'BP_EVENT_RAISE' destination 'YOURBWSYSTEMID' exporting <paramlist>. In this case you will trigger your process chain only when the record is really present, and not to overload the network and source system with extraction from ECC for every minute. Local "checking" job will generate not so much overhead.
Are this options suitable for any of your requirements?
Hope I understood them correctly.
Regards,
Andrey.