SAP BLOG How can tasks of type Job be automatically scheduled as Test Run?

SAP Blog

Kayıtlı Üye
Katılım
22 Ara 2017
Mesajlar
1,442
Tepki puanı
7
Puanları
6

Background:​


AFC is a financial close solution that brings a high level of automation into the process. One of the key features of AFC is the ability to automatically trigger, execute and report back on the execution of ABAP programs and jobs. Did you know that AFC is the only solution that can automate complex chains of jobs in SAP S/4HANA Cloud Essentials? When customers set up their Closing Structures, they often build chains and networks of automatic job executions. One well-known example is the area of fixed asset accounting. Here, customers sometimes want to first start the asset depreciation posting run in test mode and check the results, before they execute the program in real mode.

AFC supports the described scenario in different ways. While Closing Tasks of Task Type Job can be manually executed as test run by using the according button, I want to outline in this blog, how automatic scheduling by means of the Starts Immediately option can be achieved in test mode.

Manual Test Run​


First, most SAP -delivered Task Models of Task Type Job have the attribute “Test Run Possible = Yes”.

20210607_TestrunScheduling_1.jpg


Testrun-Possible-flag of Closing Tasks of type Job​

Technically, the “Test Run Possible = Yes”-attribute is controlled by the SAP -managed Parameter Type TESTR (“Test Run”), which is assigned to most of the standard closing programs in SAP delivered program registration variants.

These Closing Tasks support the action “Execute Test Run” in AFC.

20210607_TestrunScheduling_2.jpg


Action button Execute Test Run in AFC​




Note: If also the “Starts Immediately”-option is flagged for this Closing Task and it is scheduled automatically, once predecessor tasks are complete and the planned start time has passed, the Closing Task is always scheduled in real mode.

Automatic Test Run​


If you want Closing Tasks to be scheduled automatically in test mode, the respective program parameters must not be controlled by the SAP -managed Parameter Type TESTR (“Test Run”). Instead, the “Test Run” parameter must be flagged active in the program registration and you should create a separate Task Model for this purpose. You can achieve this result by taking the following steps:

  • Register an additional Program Variant with the parameter “Test Run” always active as follows:
    • Go to the “Advanced Financial Closing – Local Settings”-IMG (transaction SPRO, press F5, choose “Cross-Application Components” -> “Advanced Financial Closing – Local Settings”) and choose the IMG activity “Register Programs for Parameter Mapping”.
    • Select the respective Program with any assigned Variant ID and click the “Copy-As…” button
      20210607_TestrunScheduling_3.jpg
      or choose F6.
    • Enter a new, customer specific Variant-ID (e.g. “ZZTESTVARIANT”) and enter a meaningful Short Description in which the Program Variant is explained as a “Test Run”-only Variant, e.g. “Depreciation Posting Run (Test Mode)”.
    • Select the combination of Program, Variant ID and step into the Parameter Maintenance sub-dialog. Watch out for the Test Run parameter: it will typically be already assigned to the Parameter Type TESTR. Remove this Parameter Type assignment, select the Parameter
      20210607_TestrunScheduling_4.jpg
      and step into the Parameter Value Maintenance sub dialog. Click the Push Button New Entries or choose F5. Enter “Include” in column Sign for Ranges, “Equals” in column Range Option and “X” as value for the Parameter Low Value.
      20210607_TestrunScheduling_6.jpg.png



    • Save the new program registration.
  • Define a new Closing Business Transaction Type.
    • Choose activity “Define Closing Business Transaction Types”
    • Click New Entries or F5 and enter a suitable ID into the Closing Business Transaction Type column, e.g. ZZFADEPRUN for the Fixed Asset Depreciation Run, and provide a meaningful description, e.g. “Depreciation Posting Run (Test Mode)”. Choose Task Type “JOB” and enter the program name of the program registered in step 1.
    • Save.
  • Define a Task List Model as follows:
    • Choose the IMG activity Define Task List Model.
    • Click New Entries or F5.
    • Enter a Task Model ID, e.g. ZZFADEPRUN, the appropriate Closing Business Transaction Type (e.g. ZZFADEPRUN), the variant, in which the program has been registered in Step 1 and a meaningful description, e.g. “Depreciation Posting Run (Test Mode)”. Mark the Closing Types Month-End, Quarter-End, Year-End as desired. Enter the appropriate Application Component (e.g. FI-AA-AA-E) and select the Entity Close context.
    • Save the entry.

Upon synchronization of the respective Communication System with your Advanced Financial Closing application, the newly created Task Model can be referred to and a corresponding Closing Task can be created in your Task List Template (Create Task from Model). This Closing Task of task type Job will be executed in test mode, when scheduled.

Good to know:​


You can familiarize yourself with how to use the Define Closing Tasks app and how to process Closing tasks using the following videos:




For more information on SAP S/4HANA Cloud, check out the following links:

  • SAP Community Page for Advanced Financial Closing: here
  • SAP Help Portal for AFC: here
  • AFC in the SAP Roadmap Explorer: here
  • SAP .com page about AFC: here



Follow us via @SAP and #AdvancedFinancialClosing, or myself via Michel Loehden

Okumaya devam et...
 
Üst