Social Media Assets - DYK - Integration Studio

In Anaplan there are a number of functions that depend on the current date.  To support this, OneCloud provides a simple, yet powerful way to systematically set the current date. In this post we will walk you through the steps of building a OneCloud Chain to automate the process of setting dates in Anaplan.

Let's get started!

First, create a File Resource template that will be used in conjunction with the Handlebars BizApp to dynamically render a file that will be uploaded to Anaplan. Create a template like the following example:

File Resource

Image 1: OneCloud File Resource

Note that the variable in the file resource is replaced when the Chain is executed by the actual current date using the Handlebars BizApp Render File Template Command.  

Second, create a new OneCloud Chain and add Handlebars → Render File Template as the first Command. Configure the Command as follows:


Image 2: OneCloud Chain with Handlebars

Note that the variable name “DATE” is set to Chain execution date, a runtime System Variable. Using OneCloud Variable Transformation, this variable is then formatted to Anaplan’s convention:  YYYY-MM-DD.

Variable Transformation

Image 3: Variable transformation

In this particular example, the Chain was run on August 18, 2020.  The result of the Render File Template Command is shown below with the variable highlighted in yellow and the resulting rendered value 2020-08-18 in green.

Handlebars Result

Image 4: Run the 'Create Date' Chain

The resulting file is then uploaded and imported to the various Anaplan targets that leverage the current data utility Module(s).  OneCloud has native Commands for these steps with the Anaplan Upload File and Run Process Commands.

Upload File

Image 5: Upload File to Anaplan

Run Process

Image 6: Run Process 'Refresh Date'

In this example Chain, the rendered data is loaded to two different Anaplan Models (Datahub and Sales).

Example-Chainv2Image 7: OneCloud Chain

The final product looks like the following: 

anaplan-time-utilityWe hope this simple, yet elegant solution highlight helps you streamline your Anaplan processes.  

If you have any questions, we are here to help! Contact support,  learn more about OneCloud via the OneCloud Quick Start Guides