Anda di halaman 1dari 8

Using Workflow Builder to Implement Account Generator for Oracle Projects

Matt Skurdahl Jason Novak Oracle Corporation

Abstract You will learn how to implement Account Generator for Oracle Projects from Oracle Payables, in Release 11, specifically the Project Supplier Invoice Account Generation process. We will explain how to create Workflow Processes, how to link them to Projects and the Supplier Invoice entry function, and how to test the Processes after implementation. Scope The following details the topics included in this White Paper: I. II. III. IV. V. VI. Overview Implementation of Oracle Workflow Builder Defining Accounting Rules to be established in Workflow Builder Creating Processes within Workflow Builder Two examples Assigning Workflow Processes to Account Generator Testing Account Generator

generation. Finally, in multi-org environments where the accounting key flexfields have the same segment names, it allows the ability to apply the exact same process to multiple sets of books. As an overall description of the link between Workflow Builder, Oracle Projects and Oracle Payables, there are four steps to the account generator process. First, it is necessary to install Oracle Workflow Builder on your client. Second, create a Workflow Process to guide the account generation. Third, assign the workflow process to the item type for Supplier Invoices in the Account Generator Processes of Oracle Projects to the Accounting Flexfield. Finally, utilize Oracle Payables to pay project related invoices and allow the Account Generator to create distribution general ledger accounts. Because it is possible to utilize autoaccounting lookup sets as part of the process construction in Workflow Builder, completing autoaccounting in Oracle Projects prior to Workflow process creation is recommended. II IMPLEMENTATION BUILDER OF WORKFLOW

The information in this paper can be used for Oracle Financials Release 11.0.2 and higher and Oracle Workflow Builder v.2.0 and higher. I. OVERVIEW

Release 11 of Oracle Financial Applications utilizes Oracle Workflow Builder to generate account combinations for the Oracle General Ledger Accounting Flexfield for several applications. Previously, one would use FlexBuilder to accomplish this. In this White Paper, we review the process of using Workflow Builder to create a Process used to create account combinations during Supplier Invoice Entry. Workflow Builder provides the ability to build account combinations in Oracle Payables for Project related invoices. First, it allows organizations the ability to define account coding without requiring individual intervention from accounts payable staff members. Second, it affords the ability to create conditional statements with comparisons which may guide account

In order for you to work with Workflow Builder, you need the CDROM entitled Oracle Workflow Embedded (v2.0.3 for Oracle Applications Windows 95/Windows NT. The part number is A60742-01. In the path F(CDROM):\WF\CLIENT\WIN95, look for the SETUP.EXE file to set up Oracle Workflow Builder on your client machine. After Workflow Builder is installed, you can launch the application and then call Oracle Workflow files which reside on the server that houses the applications. It is also possible to install Workflow Builder locally without connecting to the database and then copy the Processes created to the database directory so that they are available to Oracle Financials. In order to do this, you need to obtain the correct user name and password (generally APPS/APPS), as well as the database to which you wish to connect. You then need to show a Hidden Item Type Called Project Supplier Invoice Account Generation. Make sure you click on the Show button. The following diagram documents the appearance of this form.

The application then brings up three item types: Project Supplier Invoice Account Generation, Standard and Standard Flexfield Workflow. We will be working with all three of these types as part of our Workflow Process creation.

III DEFINING ACCOUNTING RULES TO BE ESTABLISHED IN WORKFLOW BUILDER An essential part of the account generator implementation is defining how the account coding is generated. There are two options. Accounts may be entered manually by the individual completing invoice entry on the invoice distribution form; or they can be created by account generator through reference to a Workflow Process. In instances where the account coding is created by account generator, it is still possible to override the created combination through manual update. We will review mechanisms which may be used to bypass automatic account generation under the testing section of this White Paper (see section VI). In cases where the decision has been made to utilize the workflow process to create the account code combination, the following conditions merit review: Whether there are circumstances which call for a single segment value to vary based on more than one condition at a time. For instance, a single segment value could be based on the fact that the project is type of Capital and an expenditure type of Labor. In such cases, comparison functions are to be utilized, with flows to separate and distinct activity nodes based upon the result of the comparison. Preseeded comparisons functions with Workflow Builder include conditions based upon text, number or date. Whether lookup sets are to be utilized to populate segments of the accounting flexfield. Such lookup sets are

defined in the autoaccounting setups of Oracle Projects. Lookup sets are useful in cases where there is a correlation between a selected parameter and segment value. Oracle Projects comes with over 20 parameters which may be utilized in such lookup sets, including Expenditure Type, Project Name, Task Number, and many others. As an example of lookup set utilization, if the Expenditure Organization is synonymous with the Cost Center Segment of the Chart of Accounts, it is useful to have a lookup set with cost center intermediate values. When the user selects a given Expenditure Organization, the lookup set populates the cost center segment. Whether constant values are to be utilized. Assigning constant values is recommended when the segment value will not change based on the characteristics of the project or supplier invoice. This is one of the most readily defined functions within Oracle Workflow. Population of constant values is covered under our first example in section III of this White Paper. Whether it is not possible to generate the account code combination through utilization of the constant values and lookup sets. In such cases it may be necessary to utilize SQL statements, embedded within Workflow Process

functions to complete generation of the account code. The display name assigned to the Process in Workflow Builder will determine its description on the LOV in Oracle Applications on the processes window in Projects..
IV. Creating Processes within Workflow Builder We begin this section with definitions for a number items within the Oracle Workflow Builder.

Processes:
Processes are collections of activities which form a flow for a specific purpose. They are composed of individual items referred to as activity nodes. As is demonstrated in Section V of this document, for the purposes of the Project Supplier Invoice Entry, only one Workflow Process may be assigned to Account Generator. However, multiple Processes may be defined in the event that there is a multi-org environment in place. Each process would be stored on the same database and available for the multiple Projects implementations. Functions: Functions are the building blocks of workflow processes. Functions may also be synonymous with activity nodes in the workflow process. Functions can have one or more attribute values which can be modified on your workflow. For example, the Assign Value to Segment function, which we will use in both of our examples, has four separate attributes. These are: Segment Identifier, Segment, Value and Replace Existing Value. We will also see in the examples of this section, modification of the attribute values is a critical step in the development of the Workflow Process. We now provide three increasingly complex examples which utilize Workflow Builder to populate the key accounting flexfield for Supplier Invoices. Example #1: Assigning Constant Values to All Segments

In our first example, we review creating a process which consists completely of constant values for all segments within the accounting flexfield. We recognize the low likelihood that the accounting flexfield would have constant values for all segments. However, the purpose of this example is to provide a starting point for illustrating the utilization of a Workflow Process. For this example, we utilize an key accounting flexfield with six separate, independent segments. The first step is to create a new Process. This is completed by selecting the Processes directory under Project Supplier Invoice Account Generation and selecting New Process. The internal and display name are entered. The next step is to assign functions to the process. Workflow Builder provides a number of predefined functions which can be utilized within the newly created Process. These are defined under two directories: Standard, and Standard Flexfield Workflow. Highlight the function and drag it into the Process Window. All processes must have a start and end functions. In our example, we establish a start function with a type of Constant. There is no need to define attribute values either the start or end function. To assign segment values to the accounting flexfield segments, we established six independent functions with the title, Assign Value to Segment. With each of these six functions we completed the Attribute Values as follows:

Name Segment Identifier Segment Value Replace Existing Value

Value Type Constant Constant Constant Constant

Value Name Based on segment name* Based on desired value** True

Type Lookup Text Text Lookup

* This should be the name of the segment exactly as it appears in the segment name field of the accounting flexfield. **This value is the numeric value which is to be entered for the account combination.

Modification of the attribute values is completed by means of selecting the function properties and selecting

the attributes menu option. Select the OK option for each function to save the changes. Our next step is to add a function which will validate code combinations. We complete attribute values for this function as follows:

Name Validation Type New Code Combinations are Allowed

Value Type Constant Constant

Value Generate Code Combination ID True

Type Lookup Lookup

Finally, we link all of the activity nodes (in this case all of our functions). This establishes the workflow. Intuitively, the start function is the first step within the process, and the validation of the code combination immediately precedes the end generating Code

Combination. For this example, the order of the functions which assign values to segments is unimportant. We established a straight flow which represents the nature of this process. The flow may be modified in any manner the user sees fit to assist with its interpretation. The Process we have created appears in Workflow Builder as follows:

Example #2: Assigning Segment Values utilizing Autoaccounting Lookup Sets: In our second example, we have elected to populate the cost center segment of the accounting flexfield with a value which corresponds to the value of the Expenditure Organization. All other segments will be populated with constant values. As background, the expenditure organization is entered by the Oracle Payables user during invoice entry. This will provide the opportunity to select the expenditure organization from Oracle Projects and populate the field to be used by Account Generator. Before creating the Workflow Builder Process we created an autoaccounting lookup set within Oracle

Projects which we named WORKFLOW EXPENDITURE ORGANIZATION MAPPING We established intermediate values for this lookup set which correspond to both our cost center values and our expenditure organization titles. As the Workflow Process below illustrates, for the purposes of utilizing a lookup set within the account generation, we have utilized a new function/activity node entitled, Segment Lookup Set Value. As with the Assign Value to Segment function, this function is predefined by Oracle Workflow Builder. We simply dragged it into our process. We then modified the attribute values for the function as follows:

Name Lookup Set Name

Value Type Constant

Intermediate Value

Item Attribute

Value WORKFLOW EXPENDITURE ORGANIZATION MAPPING Expenditure Organization

Type Text

Text

The value for the lookup set name must exactly replicate the name used in the definition of the Lookup Set in Oracle Projects. Utilization of the Segment Lookup Set Value requires actions based upon the result of the lookup. In our example, we defined a success type which assigns the value based on the lookup set.

The option success is completed by linking the two activity nodes and selecting a success results type. This function is the same as those used for the constant value assignments in example #1. However, the attribute values will be different. We completed the attribute values as follows:

Name Segment Identifier Segment Value Replace existing value

Value Type Constant Constant Item Attribute Constant

Value Name Cost_Center* Expenditure Organization True

Type Lookup Text Text Lookup

*As with example #1, this name must exactly replicate the name given to the segment as defined in the accounting flexfield.

Finally, we have to define a result type of failure for this part of the process. In our example, we have elected to have failure result in the end of the function. When this option is selected, a failure will still allow invoice entry to continue in Oracle Payables. However, there will be no account generation, and the accounting must be completed manually on the invoice distribution form.

Alternatively, we could have elected to add an activity node with a description of Abort generating Code Combination. This would have prohibited the completion of the Payables invoice without modification to the Workflow Process. Both of these processes come predefined within Workflow Builder. End is a Standard Function, and Abort generating Code Combination is a Standard Flexfield Workflow function. In this example, no modification was required to the End function.

This process is represented in Workflow Builder graphically as follows:

In both of our examples we utilize predefined Oracle Workflow functions to create our Workflow Process. It is possible to create customized functions as well. Example #3: Assigning Segment Values utilizing both Autoaccounting Lookup Sets and Constant Values: Note: Still working on this.... V. Assigning Workflow Processes to Account Generator: Once the Workflow Process has successfully saved within Oracle Workflow Builder, the process may be associated with the account generator. This is completed through the process entitled, Select workflow process to generate accounts. In R11.02, this is on form FNDFFMWP, in Oracle Projects. To complete this requirement, select the application entitled, Oracle General Ledger and the flexfield entitled, Accounting Flexfield. Ensure that the structure references the set of books utilized for the implementation. Select Item Type entitled, Project Supplier Invoice Account Generation, and update the process name to the process created as part of Section VI. The process will be accessed via a list of values for this field (field name, WF_PROCESS_DISPLAY_NAME). Section VI, Testing, includes recommendations in cases where the process does not appear as part of this List of Values.

VI TESTING ACCOUNT GENERATOR Oracle documentation of Projects Costing/Billing s provides information which may be utilized as part of the testing process for account generator. These recommendations include testing the supplier invoice account generation process by calling the function pa_acc_gen_wf_pkg.ap_inv_generate_account in a PL/SQL block. From a practical standpoint, it may be easier to utilize testing scenarios which are completed by means of invoice entry into Oracle Payables. At this point, a review of the process which signals that Payables invoice entries are correlated with Oracle Projects is beneficial. As users enter Payables invoices, they have the opportunity to enter project information at the invoice header or distribution levels. This projects information includes the following requisite fields: Project Name Project Task Number Project Expenditure Organization Project Expenditure Date

Oracle Workflow Builder also provides the ability to use attribute values for a maximum of 15 Attributes from the Invoice Descriptive Flexfield, as well as 15 attributes from the Distribution Descriptive Flexfield in Oracle Payables. Should the Workflow Process use

these descriptive flexfields attribute values in the functions they will require definition within Oracle Payables. Once the user has input this information at the header level, account generator will define the account code combination. As the user attempts to save the invoice header information validation to the workflow process occurs. If the account generation is successful the account code combination will be created. Oracle Payables builds the expense or asset account number. For positive amounts, this is the debit side of the entry. The credit side of the entry, unless negative amounts are entered under account distribution, is assigned to the liability account as defined in the Oracle Payables implementation setups. When the user selects the Distributions button on AP form APXINWKB they will view the information in the account field. If the account generator process is unsuccessful, an error message will be displayed, and the user will be unable to save invoice information without eliminating the reference to the Project. The three most common errors which my occur when implementing the Oracle Workflow - Account Generator process are as follows: Error Type #1: Fatal Error: Error Stack: pa_acc_gen_wf_pkg.ap_inv_generate_account Error Stage: 80 Error Message: Additional Infomation1: Additional Information2: This error occurs when there is no workflow process associated with the project supplier invoice generation, or when the process which is preseeded has not been modified. Error Type #2: Fatal Error: Error Stack: pa_acc_gen_wf_pkg.ap_inv_generate_account Error Stage: 20 Error Message: Additional Infomation1: Additional Information2: This error occurs when there is a fatal error in the workflow process assigned to the project supplier invoice generation. For instance, one of the functions may have an incorrect attribute value, or type. Error Type #3: The invoice is saved at the header level, but the account field is either incomplete, or incorrect on form APXINWKB (Invoice Distributions).

This error frequently occurs when there is an end function result from the workflow process, or when the process has functions with attributes which are inappropriately defined. Suggested Actions to Resolve Account Generator Errors: We now turn our attention to methods which may be used to solve the above-referenced problems. Not all solutions will be applicable to each error. Instead, we offer general solutions which may be used as a starting point to completing a successful implementation of a workflow process to generate account coding. #1) Determine whether the workflow process appropriately references the Item Type in Projects. Ensure that the Process Name which is selected on the form, FNDFFMWP, navigation path, Setup Flexfields Key Accounts (within the Projects application) is synonymous with the process as defined in Workflow Builder. The process to be utilized must be available on the List of Values (LOV) for the Process Name Selection for Item Type, Project Supplier Invoice Account Generation. If it is not included in this LOV, reverify that the workflow process was successfully saved, and that it is under the subdirectory entitled, Processes under the Directory, Project Supplier Invoice Generation, in the database directory. In order for the process to work the workflow process must be stored within the applications. It cannot be a local file (see section II on connecting to database). #2) Set all attribute segment attributes to constant values and retest. This is a method of isolating the problem. By not using any verifying conditions within the workflow process, it is possible to ensure that the problem is not with the connection of workflow to the database, the identification of the process with supplier invoice entry, or with the start/end functions within the workflow process. Once the retest is successful, the attributes may be modified on a function by function (which may be synonymous with segment by segment within the account code generation) basis. Retesting occurs after modification to each function. Remember to resave the workflow process after each modification, and before each retesting. # 3) Test the Results of Functions which utilize Lookup Sets via the Preseeded End function. Workflow comes with a predefined End function which may be used to terminate the process without generating an account code combination. It does not have any attribute values. This may be used to test conditions

within the process by setting one of the results with this value. If the user is able to save the invoice information, but there is no account code combination generated, the user can trace the flow completed by the End function to resolve the error. This essentially bypasses the account generator process. In some cases, where the team may want payables personnel to manually enter account code combinations, this can be the preferred result. #4) Verify that the Intermediate Values utilized in the Segment Lookup Set value relate to the appropriate parameter. A frequent mistake is to map incorrect intermediate values under the Attribute Values window of the Lookup Set Value functions. For instance, the user may select the Project Organization Identifier rather than Project Organization Name. Failure to identify the correct parameter with an Error function instead of End function for the failure result of a Lookup Set Value Function will result in an error message prohibiting the user from selecting the Project Organization Identifier (in this example). Separately, it is important to ensure that any intermediate values which are utilized as part of the lookup set are defined as part of the lookup set in Oracle Projects; and that the name of the lookup set attribute be exactly the same as defined in the autoaccounting lookup sets. (See Oracle Projects, Form PAXAADCL). #5) Review attribute values for all activity nodes within the process. This is a trial and error process, and may be time consuming, but will frequently assist in successfully completing the account generation. Typical problems with attribute values are as follows: Failure to set the Replace existing value attribute to value of True when assigning values. Attempting to insert values for constants which are inconsistent with the accounting flexfield. For instance attempting to insert too few/many characters into the segment. Incorrectly identifying the Segment. The names utilized must be identical to their definition within the accounting flexfield. For instance, if a segment name is defined in Oracle General Ledger as Future_1, in Oracle Workflow it must also be Future_1, and not FUTURE_1 or Future 1 for recognition. #6) Trace the workflow process manually using actual data. Stepping through the process node by node assists in ensuring that the logic will yield the desired account code combination. Inconsistent and/or

illogical flows within the process may be uncovered during this exercise. As part of this review, determine that all segments which are included within the accounting flexfield are populated as part of the Workflow Process. Omitting a segment will prohibit population of all segments in the key accounting flexfield.

SUMMARY: In this White Paper we have provided an overview to assist in the implementation of Account Generator for Oracle Projects. Account Generator serves the purpose of allowing the Projects configuration to guide account coding for supplier invoices used to pay Projects related costs. We have provided two examples to assist in customizing a workflow process as well as recommended solutions to resolve problems which may be associated with their implementation.