58
1. Difference between Rule and Role Rule Role A Rule is a general way to 'define' your agents. A rule is maintained with Transaction code PFAC and is used to programmatically define the agents. For example, if you want a work item to go to all managers who worked for the company for 5 years or more, then you would have to create a rule that handles this custom scenario. Typically this is done by creating a custom function module that performs your selection logic and passes the results back to the rule. You can define a container element that contains the object of Organizational Management at runtime or a rule for dynamic agent determination. A Role is a general way to 'assign' your agents. A role is maintained with Transaction code PFCG and is usually assigned to a User (someone with a valid login). For example, you can have the role of ABAP_DEVELOPER and assign this role to all users who are developers. This is a good method to use if you want ALL developers to receive a workflow work item. You can specify not only a system user, but also a role or an object of Organizational Management such as a position, a Job, an organizational unit or a work center. 2. Difference between BAPI and BOR.

Sap workflow interview questions

Embed Size (px)

DESCRIPTION

Sap workflow interview questions

Citation preview

Page 1: Sap workflow interview questions

1. Difference between Rule and Role

Rule RoleA Rule is a general way to 'define' your agents.

A rule is maintained with Transaction code PFAC and is used to programmatically define the agents.

For example, if you want a work item to go to all managers who worked for the company for 5 years or more, then you would have to create a rule that handles this custom scenario. Typically this is done by creating a custom function module that performs your selection logic and passes the results back to the rule.

You can define a container element that contains the object of Organizational Management at runtime or a rule for dynamic agent determination.

A Role is a general way to 'assign' your agents.

A role is maintained with Transaction code PFCG and is usually assigned to a User (someone with a valid login).

For example, you can have the role of ABAP_DEVELOPER and assign this role to all users who are developers. This is a good method to use if you want ALL developers to receive a workflow work item.

You can specify not only a system user, but also a role or an object of Organizational Management such as a position, a Job, an organizational unit or a work center.

2. Difference between BAPI and BOR.

Page 2: Sap workflow interview questions

3 .How to assign general task? what is the use of general task?. In the agent Assignment attributes we will assign a general task Use of General Task:- you determine that all users can perform this task (in workflow).

General Forwarding Allowed

This indicator determines that work items assigned to this task can be forwarded to all users, even if the task has not been assigned to the user.

General Forwarding Not Allowed

This indicator enables you to determine that work items for this task can only be forwarded to users who are agents for the task.

If this indicator is not set, a work item for this task can be forwarded to all users.

Forwarding Not Allowed

Classification of task

Tasks can be classified into various different classes. Tasks are classified as

1.subject matter,

2 personal,

3. disciplinary or are not assigned to any class at all.

Task Properities.

Agent Assignment

Background Assignment

Task Complete

Confirm End of processing

3. what is mean by agent assignment?

Indicator denoting that the referenced single-step task has possible agents assigned to it.

Possible agent:- User who is authorized organizationally to start a task and execute the relevant work item.

Page 3: Sap workflow interview questions

List of Agen types:-

1. Expression.2. Rule

3. Organizational Unit.

4. Job

5. Position

6. Workcenter

7. User

8. Workflow Initiator

9. Superior of workflow Initiator

4. Define Substitutions and different types of Substitutions?

Substitutes are essential so that a users work items can be seen and executed by a defined replacement user. This ensures that work is not left unattended if someone is out of the office unexpectedly. Below are details of the different kinds of substitutes

Passive Substitution

If Passive substitution is used then the substitute (User B) only sees the work items of User A. User A sets up the substitution but does not activate it, then User B can Adopt the substitution if User A is out of the office unexpectedly. (As of NW04s SP04 a new setting in customizing enables you to define which work items a substitute sees when they adopt a substitution (passive substitution). If the setting is set, the substitute sees both their own work items and those of the absent user. If the setting is not set (default setting), the substitute only sees the worklist of the absent user.

Active Substitution

Active substitution (for example, for absence due to vacations): In this case, the items belonging to the absent person are automatically assigned to the substitutes inbox (in addition to his own work items).

If active substitution is used then the substitute will see their own as well as the agent they are substituting for. Active substitution is where User A is going on vacation and specifies User B as their substitute and activates the substitution.

Page 4: Sap workflow interview questions

Positional or Personal substitution

When you specify Positional substitution you can only see work items of a user that have been assigned to that position. When you use Personal substitution (Direct  substitution) you can view your own work items plus all the work items of the other user (Whether they are assigned to a position or not).

5. Dynamic parallel processing in SAP Workflow

Sometimes we need to process a dialog step (activity) several times in parallel and we may not be aware of how many times exactly this step has to be processed. Consider this scenario: For a sales order, we need to check the available quantity of the line items (materials). For each value of this list, a particular function has to be performed. So we need to create different work items for each material. This is called dynamic parallel processing, since the number of line items is known only during runtime.To achieve this, follow these steps:

1. We need to define a multiline container for the material. 2. Go to "Others" tab of the dialog step (activity) 3. Enter this workflow container element on this tab.

Restriction : The multiline element should not contain more than 99 values. At runtime, the workflow system generates from the step as many parallel work items as there are values in the multiline container element at that time. The number of values need not be known at definition time. If the table is empty, this step is ignored.

Define Binding?

Binding editor is used to define binding between elements of different containers

Points to be noted while defining binding between elements of different containers, 

Elements should belong to same data type. Binding can be defined between compatible data types. 

What is mean by Workflow Container.

5 different containers in workflow:

1. Workflow container2. Task container3. Method container4. Rule container5. Event container

Workflow container:

a. Binding can be defined from Workflow to Event Container.b. Binding can be defined from Workflow to Task Container.

Page 5: Sap workflow interview questions

c. Binding can be defined from Workflow to Rule Container.  

Event Container:

a. Binding can be defined from Event container to Workflow Container.b. Binding can be defined from Event container to Task container.

Task Container:  

a. Binding can be defined from Task to Workflow container.b. Binding can be defined from Task to Rule container.c. Binding can be defined from Task to Method container.  

Method Container: 

Binding can be defined from Method to Task container and method container.

Rule Container:

Binding can be defined from Rule container to Workflow container. 

Page 6: Sap workflow interview questions

How to customizing the business object?

customizing Business object.pdf

How to activate the workflow builder?

To set the workflow definition to status active, you select . The workflow definition is first subjected to a syntax check. Any errors and warnings discovered are displayed in the message area of the Workflow Builder. Only if errors are found, is the workflow definition not activated. If no errors are found (no red traffic lights in the message area), the workflow definition is saved and activated.

Define Rule and its types?

The rule container contains a rule’s parameters. • Each rule has just one rule container. • At runtime, the rule parameters contain the current, context-specific information that forms the basis of rule resolution. Therefore, the rule parameters constitute "input" for rule resolution. • In SAP Business Workflow, binding feeds the rule parameters with values from the workflow container. If a task contains default rules, the system fills the rule container from the task container using binding. • If a rule is used in a workflow to determine the responsible agent, the result of rule resolution is stored in the container element _RULE_RESULT and can be transferred to the workflow container by binding.

Standard Rules.

A rule container is defined for each rule. The rule parameters determine which information is required for the rule resolution

to be executed at runtime.

If an error occurs during rule resolution, setting the termination indicator for the rule

resolution determines how the workflow will continue:

Flag is selected - the workflow assumes an Error status and a notification is sent

to the workflow administrator.

Indicator is not activated - the workflow forwards this work item to ALL possible

agents.

Rule Resolution

Use

Page 7: Sap workflow interview questions

The following types of Rules can be resolved:

Agent determination rules

Agent determination rule is used in SAP Business Workflow for example, determine the responsible agents of a work item who have certain characteristics.

WebFlow Rules

WebFlow rules are used within a workflow in the basic data and in the Web activity step type.

Using a WebFlow rule you can individually execute the following parts of a Web activity:

Determination of URL Preparation of the XML document Determination of the authentication data Execution of the send procedure Determination of transfer format

How to restart the workflow?

Go T-code SWPR

Tick the check box restart immediately.

If there is no error in the workitem

1.go to tcode SWUS_WITH_REFERENCE

2. give the work item id and then execute.

Even the new workflow has been created, but the old workflow is still in the same status, so you need to logically delete the old workflow. You can do it via two ways:-

1. SWW_WI_ADMIN_CANCEL execute the function module.

Here give the workflow instance (ID) of old workflow and execute. And the new status will come as status in the execution output:-

Page 8: Sap workflow interview questions

Check the workflow logs of the old workflow, which will now show the status “Logically Deleted”:-

2. Go to transaction SWI1, enter workflow instance (ID) of old workflow and execute:-

In the output, select your work item line and click on log button:-

In the logs, double click on the first line in workflow logs:-

Page 9: Sap workflow interview questions

Then on the next screen, click on Change option in Edit menu:-

On the next screen, click on “Execute” button for “Logically Delete” option:-

Page 10: Sap workflow interview questions

Below pop-up will appear, confirm it:-

The work flow gets deleted:-

Check the old work flow logs, which will now show the status “Logically Deleted”:-

Related T-codes in workflow

saction code 

Path from area menu SAP Business Workflow (Development)

 

AWUV Wizard for event creation

Definition tools Event creation Set up with wizard

Event Creation

Page 11: Sap workflow interview questions

MCA1 Workflow Information System

Reporting Workflow Information System (WIS)

Workflow Information System (WIS)

OOAW Evaluation paths 

PFAC Maintain standard role

 Role Definition

PFAC_CHG Change roles Definition tools Standard roles Change

 

PFAC_DEL Delete roles Definition tools Standard roles Delete

 

PFAC_DIS Display roles Definition tools Standard roles Display

 

PFAC_INS Create roles Definition tools Standard roles Create

 

PFOM Maintain assignment to SAP organizational objects

Definition tools SAP org. objects Create assignments

Making Links in PD Organizational Management

PFOS Display assignment to SAP organizational objects

Definition tools SAP org. objects Display assignments

 

PFSO Organizational environment of a user

 

PFT Maintain customer task

 

PFTC General task maintenance

 Creation and Processing of Tasks

PFTC_CHG Change tasks Definition tools Tasks/Task groups

 

Page 12: Sap workflow interview questions

Change

PFTC_COP Copy tasks Definition tools Tasks/Task groups Copy

 

PFTC_DEL Delete tasks Definition tools Tasks/Task groups Delete

 

PFTC_DIS Display tasks Definition tools Tasks/Task groups Display

 

PFTC_INS Create tasks Definition tools Tasks/Task groups Create

 

PFTR Standard task for transaction

 Simplified Definition of Standard Tasks

PFTS Standard task 

PFWF Maintain workflow task (customer)

 

PFWS Maintain workflow template

 

PPOC Create organizational plan

Definition tools Organizational plan Create

Enterprise-Specific Organizational Plan

PPOM Maintain organizational plan

Definition tools Organizational plan Change

 

PPOS Display organizational plan

Definition tools Organizational plan Display

 

SWDA Ongoing settings Administration Settings

(Ongoing) Settings

Page 13: Sap workflow interview questions

SWDC Workflow editor administration data

Customizing, part of ongoing settings

Workflow Editor Administration Data Maintenance

SWDM Business Workflow Explorer

Definition tools Business Workflow Explorer

Functions of Business Workflow Explorer

SWE2 Display and maintain event type linkage

Utilities Events Type linkages

Type Linkage Table Maintenance

SWE3 Display instance linkages

Utilities Events Instance linkages

Instance Linkage Evaluation

SWE4 Switch event log on/off

Utilities Events Event log On/off

Event Log

SWEC Link change documents to events

Definition tools Event creation Change documents Linkage

Creation of Events When Change Documents Are Written

SWED Assignment of change document objects to object types

Definition tools Event creation Change documents Define workflow properties

Maintenance of Workflow-Relevant Settings for Change Documents

SWEL Display event log Utilities Events Event log Display

Event Log

SWF3 Workflow Wizard Explorer

Definition tools Wizards Workflow Wizard Explorer

Workflow Wizard Explorer

SWF4 Workflow Wizard Repository

Definition tools Wizards Workflow Wizard Repository

Workflow Wizard Repository

SWI1 Selection report for workflows

Utilities Work item selection

Selection Report for Finding Work Items

SWI2 Work item analysis Reporting Work item analysis

Work Item Analysis

Page 14: Sap workflow interview questions

SWI3 Workflow outbox Runtime tools Workflow outbox

Workflow Outbox

SWI4 Task analysis Reporting Task analysis

Task Analysis

SWI5 Workload analysis Reporting Workload analysis

Workload Analysis

SWI6 Object links Runtime tools Object links

Object Links

SWI7 Workflow resubmission folder

From integrated inbox or workflow outbox

Workflow Resubmission Folder

SWI8 Error overview Part of administration of workflow runtime system (transaction SWUF)

Error Selection

SWL1 Settings for dynamic columns

Customizing, part of ongoing settings

Defining Dynamic Columns for Integrated Inbox

SWLC Check tasks for agents

Utilities Consistency check Organizational assignment

Display Organizational Assignment

SWLD Workbench for Workflow 4.0

 Area Menu SAP Business Workflow (Development)

SWLP Copy plan version 

SWLV Maintain work item views

Customizing, part of ongoing settings

Views

SWLW Workbench for Workflow 3.0

 Area Menu SAP Business Workflow (Organization)

SWO1 Business Object Builder

Definition tools Business Object

Business Object Builder

Page 15: Sap workflow interview questions

Builder

SWO6 Customizing object types

From Business Object Builder, choose Settings Delegate System-wide

Adapting Object Types on a Customer-Specific Basis

SWU0 Event simulation Utilities Events Simulate event

Simulation: Event Creation

SWU2 RFC monitor Utilities Workflow RFC monitor

RFC Monitor

SWU3 Customizing consistency check

Utilities Customizing

Auto-Customizing and Consistency Check for Customizing

SWU4 Consistency check for standard tasks

Utilities Consistency check Task Standard task

Consistency Check for Tasks

SWU5 Consistency check for customer tasks

Utilities Consistency check Task Customer task

 

SWU6 Consistency check for workflow tasks

Utilities Consistency check Task Workflow task

 

SWU7 Consistency check for workflow templates

Utilities Consistency check Task Workflow template

 

SWU8 Switch technical trace on/off

Utilities Technical trace On/off

Technical Trace

SWU9 Display technical trace

Utilities Technical trace Display

 

SWUD Diagnostic tools Utilities Diagnosis Error Diagnosis - List of Problems and Solutions

Page 16: Sap workflow interview questions

SWUE Trigger event Utilities Events Generate event

Creation of an Event for Test Purposes

SWUF Runtime system administration

Administration Runtime system

Administration of Workflow Runtime System

SWUG Workflow start transactions

Definition tools Workflow start transactions

Definition of a Start Transaction for a Workflow

SWUI Start workflows

From the R/3 initial screen, choose

Office Start workflow

Starting a Task in Dialog

SWUS Start tasks Runtime tools Start workflow

Starting a Task in Dialog

SWUY Wizard for message linkage to workflow

Definition tools Wizards Create "Call workflow from message"

Starting a Task From Message Long Text

SWX1 Create notification of absence

 

SWX2 Change notification of absence

 

SWX3 Display notification of absence

 

SWX4 Approve notification of absence

 

SWXF Form applications: Access point

Environment Demo examples Fill out form

Demo Example: Processing a Notification of Absence

Page 17: Sap workflow interview questions

Dead line monitoring:

The runtime system allows the deadlines to be monitored for the execution of work items and the overall workflow.

Dead lines can be set and monitored for the below steps in workflow activity, user decision and wait step.

Requested startThe requested start is a technical setting and is implemented by the workflow system.

Processing is not possible before this date.

Latest start

Start byProcessing of the work item must have started by this date.

The system uses the latest start, requested end, and latest end to monitor the progress of the work item and compares these dates with the current dates that result from processing the work item.

The system triggers the actions described below if the work item has not been processed by these dates.

Requested end Processing of the work item should have been completed by this date.

 

Latest end Processing of the work item must have been completed by this date.

The deadlines are always set relative to a reference point. This reference point can be

The creation date/time of the work item. The creation date/time of the workflow containing the work item. A date that is derived from the context of the application when the specific

workflow instance is executed. This date is defined via an expression containing a reference to the workflow container.

If a deadline is exceeded, the activity/user decision involved has not yet been completed. Notification of the deadline agent or the steps following a deadline event are therefore carried out asynchronously and do not complete the original activity/user decision.

Page 18: Sap workflow interview questions

Workflow Steps:1) Activity2) Web Activity(not frequently used)3) Send Mail4) Form5) User decision6) Document from template7) Condition8) Multiple conditions9) Event Creator10) Wait11) Container Operation12) Process Control13) Loop (until)14) Fork15) Ad Hoc Anchor16) Block 17) Local Workflow

Brief Overview of Workflow Step-Types 

This WIKI will help the readers to know more about the Step-Types that are used in Workflows and a wide Implementation of these Step-Types. Apart from sending mails, Workflows can handle a lot many affairs. This will clear the air that Workflows are generally used for sending mails.

Workflows can work like Algorithms in the background as well as Foreground to make the task appear in a Flow, Basically like the Flow of Work. Various Functionalities can be Implemented like, Flow based on calculations, Flow based on Conditions, Flow based on Conditional Events, Uploading Documents, Filling up Forms etc.

Container Operation

                Container Operation is a Step-Type that is used for calculations with the help of Workflow Containers.

Page 19: Sap workflow interview questions

    

This Step-Type is used to derive various Arithmetic calculations from the Workflow Elements. To implement this Step-Type, we should give an Arithmetic Condition, based on whose result the WF moves further.

    

The various Arithmetic functions available are:

       Multiplication

Page 20: Sap workflow interview questions

       Addition

       Subtraction

       Division

One should create 3 WF Containers, for example:-

C = A + B (where all these 3 should be WF Containers)

Result Element = Source1 [(Operator)] Source2

    

Note:

       Here the Source and the Target Elements should be the Workflow Containers.

       The Outcome of this Step-Type would be Numeric/Decimal always with 1 value.

       This Arithmetic Operations take place between the values of the Workflow Containers.

    These WF Containers can have Dynamic values as well as Hard-Coded values from the WF Container.

Multiple Conditions

Page 21: Sap workflow interview questions

    Multiple Conditions is a case that is implemented where we have to check so many conditions at 1 time.Multiple Conditions can be implemented in 2 ways:-

       Case

       Switch

  

 

If the condition is like this:-                  If name = 'ABC'                                   Do this.*                       * Else if name = 'XYZ'                                   Do this.*                       * Else if name = 'PQR'                                   Do this.*                       * Else                                   Do thisIn this example ()name should always be defined as the Workflow Container Element. The values that we pass to this WF Container Element using Binding are the Actual Values that we look for Comparison. 

Page 22: Sap workflow interview questions

  

 

 Number of Values for Comparison = Number of Branches from the Multiple Condition Step-Type

    

There are 3 conditions to check the name, so now we have 3 branches that will separately process each of the Condition being implemented.

Loop

Loop is a condition that is used when one has to check for a particular Condition being FALSE or TRUE. Here we can put any Condition involving 1 or more than 1 Container Elements.

Page 23: Sap workflow interview questions

  

 

If the Condition gets satisfied, the Loop Continues or else if the Condition goes False, The Loop Terminates and Moves on to the Next Element in the WF's.

    

Process Control

Process Control is a very important Step-Type, since it performs a lot of Functions.

Page 24: Sap workflow interview questions

  

 

Now let us look at each of the Functions individually.

     

Cancel Work item

The process control step should be located in the branch of a parallel section. To uniquely identify the work item to be canceled, we must enter its node number in the 'workflow step' field. Press F4 to find all possible entries for the node numbers.

Page 25: Sap workflow interview questions

   

The work item selected is set to the status logically deleted at the time of  step execution. The workflow is not continued after this work-item. It terminates.

Cancel Work-Flow

Using this function, all work items of the workflow are set to the status logically deleted. If the step Process control is located in a workflow that is used as a sub workflow, the branch of the calling workflow that contains the sub workflow is stopped.

    

Set Work-Item to Obsolete

Use this Function, when process control is located in the branch of a modeled deadline monitoring. We can then set the work item that has exceeded its deadline, to the status completed and continue processing in the branch processing obsolete. In order to uniquely identify the work item to be cancelled, we must enter its node number in the field workflow step. Press F4 to find all possible entries for the node numbers.

Page 26: Sap workflow interview questions

    The work item selected is set to the statuscompletedat the time of step execution.

Complete Workflow

Using this function, workflow work items are set to the status completed. If the step process control is located in a workflow that is used as a sub workflow, the calling workflow is continued. For Details of Sub-Workflow or Local Workflow.

    

Cancel Workflow (Including all Callers)

Using this function, all work items of the workflow are set to the statuslogically deleted. If the step Process control is in a workflow that is to be used as a sub workflow, the calling workflow as well as all the work items in it is set to the statuslogically deleted.Thewholeworkflow is stopped using this function.

Page 27: Sap workflow interview questions

    

 

Activate Correlation

A correlation enables us to identify objects that belong together. If we have defined a correlation by using the correlation editor (Environment->Development->Correlation Editor), we can activate it here. It can then be used in a wait step.Choose the event that the correlation is to be activated for, and the correlation to be activated. Specify how the value of the correlation is to be determined:

BasisElement: If we have defined the binding in the definition of the correlation, we can specify a container element that references the corresponding basis element from the correlation definition.

Binding: Choose this entry if we want to define a binding between the Workflow container and the correlation container.  

 

In the fieldCorrelation Instance, choose the container element for the correlation object.

Page 28: Sap workflow interview questions

The correlation object shows the value of the correlation. The containerelement for the correlation object must have the predefined data type CL_SWF_MOD_CORRELATION.

Throw Exception

Here we can trigger local events of typeException.

    

We can define a local event or an exception in the version-specific basic data of the Workflow. We define the exception handler in the block.We define local events in the version-dependent basic data of the Workflow.

Local Event

  

 

Give a name to the Local Event created; here the name is'New LocalEvent'.A local event can be the following:

An exception that is triggered by a step of typeProcess Control. You define the exception handler in the block.

Page 29: Sap workflow interview questions

A local event that is triggered by an event controller or an event. You can use a local event to start a local Workflow. Furthermore, a step of typeWait for Eventcan wait for a local event.

Wait

Wait Step-Type is used when we need to wait for either an Event to happen or a Condition to get satisfied, so that we can proceed further with the Workflow.

 There are 4 conditions on which WAIT works:-

  

 

C: Wait for Condition

L: Wait for Local Event

W: Wait for Event by Using Workflow

Wait for Event.

 Let us see these individually.

  C: Wait for Condition

The wait step is complete once the specified condition has been fulfilled.

Page 30: Sap workflow interview questions

  

 

L: Wait for Local Event

This step enables us to stop the execution of this branch of our Workflow until a local event has arrived.  

 

Wait for Event  With this step, we stop the execution of this branch of our workflow until a

defined event for a particular object occurs.The object for which an event must occur must be in a container element of the workflow container. Enter the desired container element and select an associated event. We only have to define a binding if we want to use the data of the event in the workflow.

Page 31: Sap workflow interview questions

  

 

We should not use this step type in a fork to wait for an event that is triggered in another branch of the same fork.If the event arrives, it completes all wait steps that are waiting for this event.

  W: Wait for Event by Using Workflow

When waiting for an event using Workflow, the event is initially received by the Workflow and transferred to the next step, as soon as it is active.

Page 32: Sap workflow interview questions

  

 

When waiting using Workflow, an event can complete a maximum of one wait step. If more than one wait step is active, the event completes the oldest wait step.

      

Fork

This Step-Type is generally used when we need parallel processing which may or may not be based on any condition. Specifying a Condition is not mandatory for a FORK to work.

Page 33: Sap workflow interview questions

    

The number of Parallel Branches specifies that these many are the ways for parallel processing.

    

Event Creator

This Event Creator step type is used when we have to implement a BO Event or a local Event after the WF has started.

For this event Creator Step, the event must be defined for the BOR object type or class and a container element must exist in the workflow container, which refers to this BOR object type or class. Enter the required container element and choose an event. Do the necessary Binding.

We can use this event to, start or continue another workflow. 

Page 34: Sap workflow interview questions

  

 

After this Event Creator, you can implement a Local Workflow to Start based on this Event Triggering Condition.

    

After Implementing This Step-Type, the next step would continue only when this Event is created in the Application. Until and unless, this Event is satisfied, WF won't continue from here.

Document from Template

The step type 'Document from Template' enables us to create documents in Workflow with different PC applications. These documents are based on a template that we create with the PC application when we define the Workflow. This template can reference elements from the Workflow container. We can display and edit templates created in this way throughout the Workflow.The Different PC Applications are:-

Page 35: Sap workflow interview questions

    

One must have saved the Workflow to be able to create a template.The receiver of the Workflow must have installed the PC application locally on their PC to be able to execute the work item. When the Workflow is executed, the template is opened in the relevant PC application and can be completed there. The document is then saved in a container element in the Workflow container.How to create a Document Template?

Choose this Step-Type.

    

Page 36: Sap workflow interview questions

A workflow Container named WF_DOCUMENT_001 automatically gets created. Click on 'CREATE'.

  

 

Select one of the Options.

    

Page 37: Sap workflow interview questions

After Selecting a PC Application, The system fields and the container elements of the workflow container are offered for selection in the navigation area. They can be transferred into the template by double-clicking.

  

 

Select to assign a name for the document template and SAVE the Document template. Now Execute the Workflow and it gives us the Option to select from the various Templates Created. The Container Fields that we have inserted in our Template gets replaced by the Run-time Values.

Page 38: Sap workflow interview questions

  

 

Select the Document that you created and find the runtime values.

Page 39: Sap workflow interview questions

    

Form

 We can use a form to display or edit data of a container element of the workflow container that refers to a structure. We can use all the fields in the structure in the form. We can use a wizard to generate the form we need and we can edit the generated form and make our individual settings.

Depending on the action chosen, the form is displayed in either display or edit mode when executed. Additional pushbuttons are generated for the approval actions. As well as the form, the workflow toolbox is automatically available in execution.

How to create and use a FORM?

Create a WF Container – the Type of which you need the FORM to be. Select the FORM Step-Type there.

Page 40: Sap workflow interview questions

  

 

Click on CREATE.

Page 41: Sap workflow interview questions

  

 

Click on CONTINUE.

Page 42: Sap workflow interview questions

  

 

Click on CONTINUE.

Page 43: Sap workflow interview questions

  

 

Click on COMPLETE.

Form Created Successfully.

    

The FORM Format.

Page 44: Sap workflow interview questions

  

 

Now Execute the WF.

Page 45: Sap workflow interview questions

  

 

 The FORM opens up for you to fill. Just Fill the FORM and Press SAVE AND EXIT Button.

Page 46: Sap workflow interview questions

  

 

After you press the SAVE AND EXIT Button, the data gets saved in the required table from which the WF Container was made: - CRM_ORDERADM_I in this case.

Local Workflow           

        In a local Workflow we can model a part of the Workflow that is started by a local event.

Page 47: Sap workflow interview questions

 

 

In this Local Workflow we should create our own Workflow Container Elements, called as Local Containers. These additional container elements are then available to all steps that belong to this local Workflow and can be filled from the Workflow container by either an initial value or a binding.

 

 

Page 48: Sap workflow interview questions

   

We only need to define a binding if we want to use the event data in a Workflow. We must set the import indicator for local container elements that are filled by a binding from the Workflow container to ensure that the binding can be traced.

Within this Local Workflow you can still create some more WF Steps, so that this should act as a Sub-Workflow for the original WF in which this Local Workflow was created.

Create a Send-mail Step in this Local Workflow:-

Right Click on the Down Arrow for Local Exception, and Click Create. Select the Send-Mail and enter the values.

 

 

The Local Workflow Looks like this:-

Page 49: Sap workflow interview questions

   

Implement this Local Workflow after the Event Create Step-Type and see the Effect. This Local Workflow will trigger for the Specified Event happening after the start of the original Workflow. In the Event Creator Step-Type, Use the Local Workflow as the Event Creator: - TRIGGER LOCAL EVENT.

Page 50: Sap workflow interview questions

 

Page 51: Sap workflow interview questions