Global Placeholders

Placeholders allow data to be passed around while a DSD is executing, for example when passing data from one data group to be used in a second datagroup (such as the Id from the results of a MSCRM view  being used in a subsequent data group that returns data from a table in SQL).

In addition to placeholders that are set up and have a scope within a data group, global placeholders may be created that have a scope across the whole DSD.

fData_GlobalPlaceholderThe global placeholders for a DSD are shown in a panel to the right of the DSD Hub. Double click each to edit it or click Add New for a new one. In both cases the Global Placeholder dialogue will open, as shown on the right.

Enter a unique identity for the placeholder, and then specify its source data group, and its field. When the data group is executed, the value of the field will be stored in the global placeholder.

Alternatively, enter a function to be calculated whenever the placeholder is requested. A wide range of functions is available, the most commonly used and useful of which are described in a separate document.

Functions all take the form of =FUNCTION(parameters). For example, the IF function compares two value and takes one or other result depending on whether they are the same or not:

=IF(=DGROW(myDG),0,No Records,Data Exists)

This checks the current row number in the “myDG” data group and if zero (the first row) returns the text “No Records”, or “Data Exists”).

The Format is important as it specifies how the value is to be used when substituting a dummy value when simulating the data group to establish available fields. The Text List format also converts the value (in live running and simulation) by adding single quotes to each value in the list (e.g. a,b,c becomes ‘a’,’b’,’c’), which is especially important for IN conditions in SQL WHERE clauses.

image_pdfimage_print