Create Type From Data
  • 22 Sep 2021
  • 2 Minutes to read
  • Dark
    Light
  This documentation version is deprecated, please click here for the latest version.

Create Type From Data

  • Dark
    Light

Article summary

Overview

In some instances, a user may wish to recreate or track data from a specific Flow. To aid in this, users may utilize the Create Type From Data feature. Create Type From Data is a function found in the Data Definitions window that compiles the configured Data Definitions and converts them into a singular Defined Data Structure

The following document discusses how to use the Create Type From Data function to convert two String [Text] definitions, into a Defined Data Structure.


Example

Create a Flow that will use the Create Data Step to Create Type From Data in order to make a Flow Structure of the items in the flow. To show the flow structure mapping further down the flow, we will start off the flow with two constant strings and map them in Show Form and Create Data steps.

Steps Used in Example:

  • Create Data: All Steps [Catalog] > Data > Create Data
  • Show Form: All Steps [Catalog] > Form [Interaction] > Default > Show Form

2019-07-12_114918.PNG

Configure The Steps:

Begin in a Designer Folder in the bottom action panel select Create Flow, name the flow and select Create.

2019-07-12_114952.PNG

In the Flow Designer, select the Start Step and navigate to Properties > Flow Data and select Show Editor. Create two inputs of the ‘String’ type. In this example, name one EmployeeName and EmployeeEmail.

2019-07-12_115011.PNG

For the string inputs, change the mapping type to constant and use an example string for both Inputs. In this example, use EmployeeName Kim Smith and EmployeeEmail kimsmith@emailexample.123.

2019-07-12_115032.PNG

2019-07-12_115103.PNG

Next, connect a Show Form step to input the two strings created. Create the Form to look like below.

2019-07-12_115126.PNG

  1. Label: Employee’s Name
  2. Label: Employee’s Email
  3. Text Box: Data Name -> EmployeeName
  4. Text Box: Data Name -> EmployeeEmail
  5. Button: Button Text -> Submit

Save and close the Form, make sure the inputs and outputs in the properties for the Form are correct.

2019-07-12_115153.PNG

Next, drag and drop the Create Data step to Create Type From Data. Navigate to Properties > Data > Data To Create and select Show Editor. Select Create Type From Data. Name the data name field Company, select Create.

2019-07-12_115221.PNG

After "Company" is created, select Edit Type to create two strings for EmployeeEmail and EmployeeName. Select SAVE.

2019-07-12_115245.PNG

In Inputs, select Edit then Build Data for Company. If Build Data does not populate in the dropdown, save and close the flow to recompile.

2019-07-12_115313.PNG

Then for EmployeeEmail and EmployeeName, Select From Flow for the inputs. Close out of Data Definitions. This will create a Flow Structure called Company with two strings.

2019-07-12_115335.PNG

Here is the mapping of the two strings going into the Create Type From Data.

2019-07-12_115356.PNG

After everything is completed and mapped, debug the flow. The form shows select Submit and the flow will create a Flow Structure from the Create Data Step.

2019-07-12_115414.PNG

Now there is a Flow Structure named Company with strings EmployeeEmail and EmployeeName.

2019-07-12_115432.PNG



Was this article helpful?