http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/00a1f389-ec7c-2c10-04bc-9d81b3084171?overridelayout=true
Showing posts with label Process Chains. Show all posts
Showing posts with label Process Chains. Show all posts
All about Process Chains.... Tips
Posted by Sharath Labels: business intelligence dashboard, business intelligence Training, Process Chains, sap bw
By: Chandiraban singu
Process chain:
A Process chain is a sequence of processes that wait in the background for an event. Some of these processes trigger a separate event that can start other processes in turn.
If you use Process chains, you can
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/00a1f389-ec7c-2c10-04bc-9d81b3084171?overridelayout=true
All about Process Chains... in SAP BW Step By Step
Posted by Sharath Labels: bi certification material, business intelligence dashboard, business intelligence Training, BW, Process Chains, SAP bi certification material, sap bi process chain issue, sap bi stuff, sap BI support issues
By: Anonymous
I want to continue my series for beginners new to SAP BI. In this blog I write down the necessary steps how to create a process chain loading data with an infopackage and with a DTP, activation and scheduling of this chain.
1.) Call transaction RSPC
RSPC is the central transaction for all your process chain maintenance. Here you find on the left existing process chains sorted by “application components”. The default mode is planning view. There are two other views available: Check view and protocol view.
2.) Create a new process chain
To create a new process chain, press “Create” icon in planning view. In the following pop-Up window you have to enter a technical name and a description of your new process chain.
The technical name can be as long as up to 20 characters. Usually it starts with a Z or Y. See your project internal naming conventions for it.
3.) Define a start process
After entering a process chain name and description, a new window pop-ups. You are asked to define a start variant.
That’s the first step in your process chain! Every process chain does have one and only one starting step. A new step of type “Start process” will be added. To be able to define unique start processes for your chain you have to create a start variant. These steps you have to do for any other of the subsequent steps. First drag a process type on the design window. Then define a variant for this type and you have to create a process step. The formula is:
Process Type + Process Variant = Process Step!
If you save your chain, process chain name will be saved into table RSPCCHAIN. The process chain definition with its steps is stored into table RSPCPROCESSCHAIN as a modified version.So press on the “create” button, a new pop-up appears:
Here you define a technical name for the start variant and a description. In the n ext step you define when the process chain will start. You can choose from direct scheduling or start using meta chain or API. With direct scheduling you can define either to start immediately upon activating and scheduling or to a defined point in time like you know it from the job scheduling in any SAP system. With “start using meta chain or API” you are able to start this chain as a subchain or from an external application via a function module “RSPC_API_CHAIN_START”. Press enter and choose an existing transport request or create a new one and you have successfully created the first step of your chain.
4.) Add a loading step
If you have defined the starting point for your chain you can add now a loading step for loading master data or transaction data. For all of this data choose “Execute infopackage” from all available process types. See picture below:
You can easily move this step with drag & drop from the left on the right side into your design window.A new pop-up window appears. Here you can choose which infopackage you want to use. You can’t create a new one here. Press F4 help and a new window will pop-up with all available infoapckages sorted by use. At the top are infopackages used in this process chain, followed by all other available infopackages not used in the process chain. Choose one and confirm. This step will now be added to your process chain. Your chain should look now like this:
How do you connect these both steps? One way is with right mouse click on the first step and choose Connect with -> Load Data and then the infopackage you want to be the successor.
Another possibility is to select the starting point and keep left mouse button pressed. Then move mouse down to your target step. An arrow should follow your movement. Stop pressing the mouse button and a new connection is created. From the Start process to every second step it’s a black line.
5.) Add a DTP process In BI 7.0 systems you can also add a DTP to your chain. From the process type window ( see above.) you can choose “Data Transfer Process”. Drag & Drop it on the design window. You will be asked for a variant for this step. Again as in infopackages press F4 help and choose from the list of available DTPs the one you want to execute. Confirm your choice and a new step for the DTP is added to your chain. Now you have to connect this step again with one of its possible predecessors. As described above choose context menu and connect with -> Data transfer process. But now a new pop-up window appears.
Here you can choose if this successor step shall be executed only if the predecessor was successful, ended with errors or anyhow if successful or not always execute. With this connection type you can control the behaviour of your chain in case of errors. If a step ends successful or with errors is defined in the process step itself. To see the settings for each step you can go to Settings -> Maintain Process Types in the menu. In this window you see all defined (standard and custom ) process types. Choose Data transfer process and display details in the menu. In the new window you can see:
DTP can have the possible event “Process ends “successful” or “incorrect”, has ID @VK@, which actually means the icon and appears under category 10, which is “Load process and post-processing”. Your process chain can now look like this:
You can now add all other steps necessary. By default the process chain itself suggests successors and predecessors for each step. For loading transaction data with an infopackage it usually adds steps for deleting and creating indexes on a cube. You can switch off this behaviour in the menu under “Settings -> Default Chains". In the pop-up choose “Do not suggest Process” and confirm.
Then you have to add all necessary steps yourself.
6.) Check chain
Now you can check your chain with menu “Goto -> Checking View” or press the button “Check”. Your chain will now be checked if all steps are connected, have at least one predecessor. Logical errors are not detected. That’s your responsibility. If the chain checking returns with warnings or is ok you can activate it. If check carries out errors you have to remove the errors first.
7.) Activate chain
After successful checking you can activate your process chain. In this step the entries in table RSPCPROCCESSCHAIN will be converted into an active version. You can activate your chain with menu “Process chain -> Activate” or press on the activation button in the symbol bar. You will find your new chain under application component "Not assigned". To assign it to another application component you have to change it. Choose "application component" button in change mode of the chain, save and reactivate it. Then refresh the application component hierarchy. Your process chain will now appear under new application component.
8.) Schedule chain
After successful activation you can now schedule your chain. Press button “Schedule” or menu “Execution -> schedule”. The chain will be scheduled as background job. You can see it in SM37. You will find a job named “BI_PROCESS_TRIGGER”. Unfortunately every process chain is scheduled with a job with this name. In the job variant you will find which process chain will be executed. During execution the steps defined in RSPCPROCESSCHAIN will be executed one after each other. The execution of the next event is triggered by events defined in the table. You can watch SM37 for new executed jobs starting with “BI_” or look at the protocol view of the chain.
9.) Check protocol for errors
You can check chain execution for errors in the protocol or process chain log. Choose in the menu “Go to -> Log View”. You will be asked for the time interval for which you want to check chain execution. Possible options are today, yesterday and today, one week ago, this month and last month or free date. For us option “today” is sufficient.
Here is an example of another chain that ended incorrect:
On the left side you see when the chain was executed and how it ended. On the right side you see for every step if it ended successfully or not. As you can see the two first steps were successfull and step “Load Data” of an infopackage failed. You can now check the reason with context menu “display messages” or “Process monitor”. “Display messages” displays the job log of the background job and messages created by the request monitor. With “Process monitor” you get to the request monitor and see detailed information why the loading failed. THe logs are stored in tables RSPCLOGCHAIN and RSPCPROCESSLOG. Examining request monitor will be a topic of one of my next upcoming blogs.
10.) Comments
Here just a little feature list with comments.
- You can search for chains, but it does not work properly (at least in BI 7.0 SP15).
- You can copy existing chains to new ones. That works really fine.
- You can create subchains and integrate them into so-called meta chains. But the application component menu does not reflect this structure. There is no function available to find all meta chains for a subchain or vice versa list all subchains of a meta chain. This would be really nice to have for projects.
- Nice to have would be the possibility to schedule chains with a user defined job name and not always as "BI_PROCESS_TRIGGER".
But now it's your turn to create process chains.
1.) Call transaction RSPC
RSPC is the central transaction for all your process chain maintenance. Here you find on the left existing process chains sorted by “application components”. The default mode is planning view. There are two other views available: Check view and protocol view.
2.) Create a new process chain
To create a new process chain, press “Create” icon in planning view. In the following pop-Up window you have to enter a technical name and a description of your new process chain.
The technical name can be as long as up to 20 characters. Usually it starts with a Z or Y. See your project internal naming conventions for it.
3.) Define a start process
After entering a process chain name and description, a new window pop-ups. You are asked to define a start variant.
That’s the first step in your process chain! Every process chain does have one and only one starting step. A new step of type “Start process” will be added. To be able to define unique start processes for your chain you have to create a start variant. These steps you have to do for any other of the subsequent steps. First drag a process type on the design window. Then define a variant for this type and you have to create a process step. The formula is:
Process Type + Process Variant = Process Step!
If you save your chain, process chain name will be saved into table RSPCCHAIN. The process chain definition with its steps is stored into table RSPCPROCESSCHAIN as a modified version.So press on the “create” button, a new pop-up appears:
Here you define a technical name for the start variant and a description. In the n ext step you define when the process chain will start. You can choose from direct scheduling or start using meta chain or API. With direct scheduling you can define either to start immediately upon activating and scheduling or to a defined point in time like you know it from the job scheduling in any SAP system. With “start using meta chain or API” you are able to start this chain as a subchain or from an external application via a function module “RSPC_API_CHAIN_START”. Press enter and choose an existing transport request or create a new one and you have successfully created the first step of your chain.
4.) Add a loading step
If you have defined the starting point for your chain you can add now a loading step for loading master data or transaction data. For all of this data choose “Execute infopackage” from all available process types. See picture below:
You can easily move this step with drag & drop from the left on the right side into your design window.A new pop-up window appears. Here you can choose which infopackage you want to use. You can’t create a new one here. Press F4 help and a new window will pop-up with all available infoapckages sorted by use. At the top are infopackages used in this process chain, followed by all other available infopackages not used in the process chain. Choose one and confirm. This step will now be added to your process chain. Your chain should look now like this:
How do you connect these both steps? One way is with right mouse click on the first step and choose Connect with -> Load Data and then the infopackage you want to be the successor.
Another possibility is to select the starting point and keep left mouse button pressed. Then move mouse down to your target step. An arrow should follow your movement. Stop pressing the mouse button and a new connection is created. From the Start process to every second step it’s a black line.
5.) Add a DTP process In BI 7.0 systems you can also add a DTP to your chain. From the process type window ( see above.) you can choose “Data Transfer Process”. Drag & Drop it on the design window. You will be asked for a variant for this step. Again as in infopackages press F4 help and choose from the list of available DTPs the one you want to execute. Confirm your choice and a new step for the DTP is added to your chain. Now you have to connect this step again with one of its possible predecessors. As described above choose context menu and connect with -> Data transfer process. But now a new pop-up window appears.
Here you can choose if this successor step shall be executed only if the predecessor was successful, ended with errors or anyhow if successful or not always execute. With this connection type you can control the behaviour of your chain in case of errors. If a step ends successful or with errors is defined in the process step itself. To see the settings for each step you can go to Settings -> Maintain Process Types in the menu. In this window you see all defined (standard and custom ) process types. Choose Data transfer process and display details in the menu. In the new window you can see:
DTP can have the possible event “Process ends “successful” or “incorrect”, has ID @VK@, which actually means the icon and appears under category 10, which is “Load process and post-processing”. Your process chain can now look like this:
You can now add all other steps necessary. By default the process chain itself suggests successors and predecessors for each step. For loading transaction data with an infopackage it usually adds steps for deleting and creating indexes on a cube. You can switch off this behaviour in the menu under “Settings -> Default Chains". In the pop-up choose “Do not suggest Process” and confirm.
Then you have to add all necessary steps yourself.
6.) Check chain
Now you can check your chain with menu “Goto -> Checking View” or press the button “Check”. Your chain will now be checked if all steps are connected, have at least one predecessor. Logical errors are not detected. That’s your responsibility. If the chain checking returns with warnings or is ok you can activate it. If check carries out errors you have to remove the errors first.
7.) Activate chain
After successful checking you can activate your process chain. In this step the entries in table RSPCPROCCESSCHAIN will be converted into an active version. You can activate your chain with menu “Process chain -> Activate” or press on the activation button in the symbol bar. You will find your new chain under application component "Not assigned". To assign it to another application component you have to change it. Choose "application component" button in change mode of the chain, save and reactivate it. Then refresh the application component hierarchy. Your process chain will now appear under new application component.
8.) Schedule chain
After successful activation you can now schedule your chain. Press button “Schedule” or menu “Execution -> schedule”. The chain will be scheduled as background job. You can see it in SM37. You will find a job named “BI_PROCESS_TRIGGER”. Unfortunately every process chain is scheduled with a job with this name. In the job variant you will find which process chain will be executed. During execution the steps defined in RSPCPROCESSCHAIN will be executed one after each other. The execution of the next event is triggered by events defined in the table. You can watch SM37 for new executed jobs starting with “BI_” or look at the protocol view of the chain.
9.) Check protocol for errors
You can check chain execution for errors in the protocol or process chain log. Choose in the menu “Go to -> Log View”. You will be asked for the time interval for which you want to check chain execution. Possible options are today, yesterday and today, one week ago, this month and last month or free date. For us option “today” is sufficient.
Here is an example of another chain that ended incorrect:
On the left side you see when the chain was executed and how it ended. On the right side you see for every step if it ended successfully or not. As you can see the two first steps were successfull and step “Load Data” of an infopackage failed. You can now check the reason with context menu “display messages” or “Process monitor”. “Display messages” displays the job log of the background job and messages created by the request monitor. With “Process monitor” you get to the request monitor and see detailed information why the loading failed. THe logs are stored in tables RSPCLOGCHAIN and RSPCPROCESSLOG. Examining request monitor will be a topic of one of my next upcoming blogs.
10.) Comments
Here just a little feature list with comments.
- You can search for chains, but it does not work properly (at least in BI 7.0 SP15).
- You can copy existing chains to new ones. That works really fine.
- You can create subchains and integrate them into so-called meta chains. But the application component menu does not reflect this structure. There is no function available to find all meta chains for a subchain or vice versa list all subchains of a meta chain. This would be really nice to have for projects.
- Nice to have would be the possibility to schedule chains with a user defined job name and not always as "BI_PROCESS_TRIGGER".
But now it's your turn to create process chains.
There are sometimes doubts regarding how to set up processes within the process chains. Process chain is structural and logical grouping of processes , jobs or steps involved within loading of data into BW. Proper design of chain has effects on its performance and consequently on performance of whole BW system. Therefore kind of best practice I can recommend following sequence for designing process chains:
a. Delete Index
b. Data Transfer Process / Execute InfoPackage – optimally in parallel
c. Generate Index
d. Construct Database Statistics
e. Compress cube
f. Delete PSA (aged data requests)
g. Delete Change Log (aged data requests)
DataFlow of Process Chains in different SAP BW-BI
Steps for Process Chains in BI 7.0 for a Cube.
1. Start
2. Execute Infopackage
3. Delete Indexes for Cube
4.Execute DTP
5. Create Indexes for Cube
For DSO
1. Start
2. Execute Infopackage
3. Execute DTP
5. Activate DSO
For an IO
1. Start
2.Execute infopackage
3.Execute DTP
4.Attribute Change Run
Data to Cube thru a DSO
1. Start
2. Execute Infopackage ( loads till psa )
3.Execute DTP ( to load DSO from PSA )
4.Activate DSO
5.Further Processing
6.Delete Indexes for Cube
7.Execute DTP ( to load Cube from DSO )
8.Create Indexes for Cube
SAP BW 3.X
Master loading ( Attr, Text, Hierarchies )
Steps :
1.Start
2. Execute Infopackage (say if you are loading 2 IO's just have them all parallel )
3.You might want to load in seq - Attributes - Texts - Hierarchies
4.And ( Connecting all Infopackages )
5.Attribute Change Run ( add all relevant IO's ).
Start
\/
Infopackge1A(Attr)Infopackge2A(Attr)
\/
Infopackge1B(Txts)Infopackge2B(Txts)
/_____________________
Infopackge1C(Txts)______
\_____________________
_\____________________
__\___________________
___\__________________
_____\________________/
______ _And Processor__ ( Connect Infopackge1C & Infopackge2B )
____________________
Attribute Change Run ( Add InfoObject 1 & InfoObject 2 to this variant )
1. Start
2. Delete Indexes for Cube
3. Execute Infopackage
4.Create Indexes for Cube
For DSO
1. Start
2. Execute Infopackage
3. Activate DSO
For an IO
1.Start
2.Execute infopackage
3.Attribute Change Run
Data to Cube thru a DSO
1. Start
2. Execute Infopackage (Loads till PSA)
3.Activate DSO
5.Further Processing
6.Delete Indexes for Cube
7.Execute Infopackage
8.Create Indexes for Cube
a. Delete Index
b. Data Transfer Process / Execute InfoPackage – optimally in parallel
c. Generate Index
d. Construct Database Statistics
e. Compress cube
f. Delete PSA (aged data requests)
g. Delete Change Log (aged data requests)
DataFlow of Process Chains in different SAP BW-BI
Steps for Process Chains in BI 7.0 for a Cube.
1. Start
2. Execute Infopackage
3. Delete Indexes for Cube
4.Execute DTP
5. Create Indexes for Cube
For DSO
1. Start
2. Execute Infopackage
3. Execute DTP
5. Activate DSO
For an IO
1. Start
2.Execute infopackage
3.Execute DTP
4.Attribute Change Run
Data to Cube thru a DSO
1. Start
2. Execute Infopackage ( loads till psa )
3.Execute DTP ( to load DSO from PSA )
4.Activate DSO
5.Further Processing
6.Delete Indexes for Cube
7.Execute DTP ( to load Cube from DSO )
8.Create Indexes for Cube
SAP BW 3.X
Master loading ( Attr, Text, Hierarchies )
Steps :
1.Start
2. Execute Infopackage (say if you are loading 2 IO's just have them all parallel )
3.You might want to load in seq - Attributes - Texts - Hierarchies
4.And ( Connecting all Infopackages )
5.Attribute Change Run ( add all relevant IO's ).
Start
\/
Infopackge1A(Attr)Infopackge2A(Attr)
\/
Infopackge1B(Txts)Infopackge2B(Txts)
/_____________________
Infopackge1C(Txts)______
\_____________________
_\____________________
__\___________________
___\__________________
_____\________________/
______ _And Processor__ ( Connect Infopackge1C & Infopackge2B )
____________________
Attribute Change Run ( Add InfoObject 1 & InfoObject 2 to this variant )
1. Start
2. Delete Indexes for Cube
3. Execute Infopackage
4.Create Indexes for Cube
For DSO
1. Start
2. Execute Infopackage
3. Activate DSO
For an IO
1.Start
2.Execute infopackage
3.Attribute Change Run
Data to Cube thru a DSO
1. Start
2. Execute Infopackage (Loads till PSA)
3.Activate DSO
5.Further Processing
6.Delete Indexes for Cube
7.Execute Infopackage
8.Create Indexes for Cube
Subscribe to:
Posts (Atom)