EducationSoftwareStrategy.com
StrategyCommunity

Knowledge Base

Product

Community

Knowledge Base

TopicsBrowse ArticlesDeveloper Zone

Product

Download SoftwareProduct DocumentationSecurity Hub

Education

Tutorial VideosSolution GalleryEducation courses

Community

GuidelinesGrandmastersEvents
x_social-icon_white.svglinkedin_social-icon_white.svg
Strategy logoCommunity

© Strategy Inc. All Rights Reserved.

LegalTerms of UsePrivacy Policy
  1. Home
  2. Topics

KB12129: How to create an attribute element filter that uses comparison operators such as greater than or less than in MicroStrategy Developer 9.4.x-10.x


Stefan Zepeda

Salesforce Solutions Architect • Strategy


This article explains how to create an attribute element filter that uses any other operator than the exactly or equal operators

Currently, attribute element filters can only be used with an exactly or equal operator.
To create an attribute element filter that uses any other operator, complete the following steps in Strategy Tutorial:
Note: The goal of this example is to retrieve a list of months whose ID is greater than the one selected through attribute element prompt.

  • Create a duplicate of the Month attribute and name it 'AliasMonth'
  • Create a filter that will prompt users to select the Month attribute. This example uses 'AliasMonth' to build the filter as shown in the image below:
ka04W000001Ir3nQAC_0EM440000002Fhq.jpeg
  • Build a report using the filter created above. Add 'AliasMonth' to the report template as shown in the image below:
ka04W000001Ir3nQAC_0EM440000002FhY.jpeg
  • Create a report, and add the above report as a filter. Add also AliasMonth to the report template as Report Object (not being displayed).
     
  • Create an attribute qualification on the Month attribute ID greater than the AliasMonth attribute ID as shown in the image below:
ka04W000001Ir3nQAC_0EM440000002Fhc.jpeg
  • The report will return the list of months having an ID greater than the month selected in the report as the filter as shown in the image below:
ka04W000001Ir3nQAC_0EM440000002Fha.jpeg
  • Create a final report by using the report created in Step 4 to get the list of months as a filter. Add AliasMonth in addition to "normal" month on the template as Report Object (not being displayed). It will prompt the user to select a month as shown in the image below:
ka04W000001Ir3nQAC_0EM440000002Fhe.jpeg
  • The result after execution is as follows. Users are now able to perform a join on the list of months selected.
ka04W000001Ir3nQAC_0EM440000002Fho.jpeg

Note: If metrics or other attributes are added into the report in Step 4, then the report will ignore the list of month and will show data for only the month selected in the prompt.
 
IMPORTANT NOTE: The Very Large Database (VLDB) property "Engine Attribute Role Options" has to be enabled. The VLDB property "Engine Attribute Role Options" can be found under Project Configuration -> Database instances -> VLDB Properties -> Query Optimizations.
 
More information about Attribute Roles and why they are needed:
KB6197: How do Attribute Roles Work in MicroStrategy?


Comment

0 comments

Details

Knowledge Article

Published:

April 19, 2017

Last Updated:

April 19, 2017