Create a Reusable Query Template
There are two types of steps that enable you to create a query template that is reusable across data layers and graphmarts:
Templated Step
Templated Steps use user-defined key-value pairs. The keys are represented by parameters in the query. Creating the key-value pairs requires familiarity with the data and properties defined in the model. When this step is reused, users do not need to rewrite the query; they modify the values for the keys.
Query-Driven Templated Step
Query-Driven Templated Steps are similar to Templated Steps in that they provide a way to create query templates that use parameters to represent key-value pairs. The queries are reusable across datasets because the existing parameters can be substituted for alternate key-value pairs. The difference between the two types of steps is that the key-value pairs for Templated Steps are user-defined. In Query-Driven Templated Steps, a parameter query is run that automatically generates the key-value pairs. Then the defined template query is run for each key-value solution from the parameter query.
This section includes instructions for creating both types of templated steps.