Custom Configurations with the DirectScale Query Language

The Custom Configuration field is a Multi-faceted Configuration field that allows you to customized the visibility of an element based on any data point in the system.

Custom Configuration field

For example, if you want your content to display the viewed user that is in the Binary Tree but not personally enrolled by the viewing user, you can enter the following query:

(User.DownlineLevel(‘Placement’) > 0 AND (User.DownlineLevel(‘Enrollment’) > 0) == false) OR (User.DownlineLevel(‘Placement’) > 0 AND (User.DownlineLevel(‘Enrollment’) > 1)

This query is made up of two statements connected by an OR operator:

  • Associates that are in the viewer’s Binary Tree only (not in Enrollment Tree):

    User.DownlineLevel(‘Placement’) > 0 AND (User.DownlineLevel(‘Enrollment’) > 0) == false

    Associates in both the viewer’s Binary Tree and Enrollment Tree but are not Personally Enrolled (which would be enrollment level ‘== 1’) nor the viewer themselves (which would be enrollment level ‘== 0’).


The Custom Configuration field features a type-ahead style feature that provides syntax options as you type.


The AutoComplete menu features all available Entities, Properties, and Operators.

To select a suggestion, you can:

  • Use your keyboard’s or keys to highlight a select. Then press TAB to select
  • Finish typing the syntax, using the AutoComplete as a reference
  • Use your mouse to select the suggestion


The query language uses simple syntax made up of four elements:

User.Country IN (‘AU, ‘CA’, ‘US’)
  1. Entity
  2. Property
  3. Operator
  4. Values

User Entity

The User entity can access any Data Point Category in the system.

  • User.CommissionsGroupVolume
  • User.AssociateName
  • User.CommissionsCV

Get Data Point Categories

See a full list here: Get Data Point Categories (GADP)

Commission-specific Values

Access commission-specific values from previous periods.

  • User.CommissionsCV.MonthsAgo(1) – CV from 1 month ago
  • User.CommissionsGroupVolume.WeeksAgo(1) – Group Volume from 1 week ago

You can establish strings that target the relationship of the User viewing information and the users whose data is being viewed.

Important: When using these properties, the user describes the viewed user (such as the one being viewed), rather than the viewer (the currently logged-in user).

  • User.IsCurrentUser – The user data being viewed is the same as the currently logged-in User.

  • User.DownlineLevel('<treeType>') – The Associate whose data is being viewed gets the number of levels below the currently logged-in user in the given tree.

  • User.DownlineLevel('<treeType>') – This is similar to the DownlineLevel property but is used to target the direct upline of a user in a tree instead.

Note: These properties that target tree hierarchies are only applicable in situations like Data Privacy or the Team Dashboard where the restriction is based on a relationship between two users.

The valid treeTypes are:

  • ‘Enrollment’
  • ‘Placement’ (such as Binary or Unilevel)
  • ‘Matrix’

Only Showing Elements Impersonating Web Office

  • User.IsImpersonated – If you have an element or page in Web Office that you only want to be visible or accessible by corporate admins, you can use the User.IsImpersonated rule.

With this rule, elements will not display in Web Office for associates. Only admins using the Impersonate in Office feature will see the element.

Now Entity

Gets a DateTime object that is set to the current date and time. Dates are expressed as strings.

‘2016-01-01 00:00 AM Central Standard Time’


Property Definition
Day Gets the day of the month represented by this instance. Days are expressed as integers.
Hour Gets the hour component of the date represented by this instance. Hour is expressed as an integer between 0 and 23.
Minute Gets the minute component of the date represented by this instance. Minutes are represented as integers.
Month Gets the month component of the date represented by this instance. Months are represented as integers.
Year Gets the year component of the date represented by this instance. Years are represented as integers.
AddDays(1) Add or subtract days from the current. Integers can be positive or negative.
AddHours(1) Add or subtract hours from the current. Integers can be positive or negative.
AddYears(1) Add or subtract years from the current. Integers can be positive or negative.


Operator Definition
IN String is one of…
NOT IN String does not contain…
== Equals
!= Does not equal
>= Greater than or equal to
<= Less than or equal to
> Great than
< Less than
(xxx) Specify order of operations or string groups


Value Example
Dates ‘YYY-MM-DD HH:MM AM Timezone’ (HH:MM is optional) '2016-01-01 00:00 AM Central Standard Time'
Strings ('string')
Multiple Strings ('string 1', 'string 2', 'string 3')
Multiple Integers (12345, 456789, 98765)
Boolean 'True' or 'False'


Prompt Code
Your content will be displayed to users in Australia, Canada, or the United States. User.Country IN (‘AU’, ‘CA’, ‘US’)
Your content will be displayed to users in Australia, Canada, or the United States that speak English. User.Country IN (‘AU’, ‘CA’, ‘US’) AND User.Language == ‘en’
Your content will be displayed starting on Jan. 1, 2019. Now >= '2019-01-01 00:00 AM Central Standard Time'
Your content will be displayed to users who enrolled in 2019 after the 20th day of any month. (User.AssociateEnrollmentDate.Year == 2019 AND User.AssociateEnrollmentDate.Day > 20)
Your content will be displayed to users in the United States who enrolled within the last (rolling) 30 days. User.Country IN ('US') AND (User.AssociateEnrollmentDate > Now.AddDays(-30))
Your content will be displayed to users in Canada who are Active and they are Ambassadors. User.Country IN ('CA') AND User.UserStatus IN ('Active') AND User.UserType IN ('Ambassador')
Your content will be displayed only on the logged-in user’s birthday User.AssociateBirthDate.Month == Now.Month AND User.AssociateBirthDate.Day == Now.Day
Your content will display the viewed User that is personally enrolled by the viewer (or, in other words, on level 1 of the viewer’s Enrollment Tree). User.DownlineLevel('Enrollment') == 1
Your content will display the viewed User that is more than one level below the viewer in the enrollment tree. User.DownlineLevel('Enrollment') > 1

Note: If the viewed user is not in the viewer’s enrollment tree downline, or if the viewed user is the viewer themselves (such as, the user is viewing his own data) This example will return false.
Was this article helpful?
1 out of 1 found this helpful
Previous Next



Please sign in to leave a comment.