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

KB13829: Attribute element filter returns unexpected results after changing the warehouse database and the lookup tables in the new warehouse are populated differently in MicroStrategy Developer 10.x


Stefan Zepeda

Salesforce Solutions Architect • Strategy


Attribute element filter returns unexpected results after changing the warehouse database and the lookup tables in the new warehouse are populated differently in MicroStrategy Developer 10.x

SYMPTOM:
Consider a scenario where in a development environment in Strategy Developer 10.x, a user creates a report with a report filter as follows:

ka02R000000kbFLQAY_0EM440000002FVH.jpeg

 
Region In list (France, Germany, Canada)
The lookup table for the Region attribute contains the following entries:

ka02R000000kbFLQAY_0EM440000002FVD.jpeg

 
The following WHERE clause is generated for the report filter:
where a11.[REGION_ID] in (9, 10, 11)
The project is now migrated to the production environment. The lookup table for the Region attribute in the production environment contains the following entries:

ka02R000000kbFLQAY_0EM440000002FVF.jpeg

 
However, when executing the report in the production environment, the WHERE clause is still is generated as it was in the development environment:
where a11.[REGION_ID] in (9, 10, 11)
This will result in incorrect data for this report in the production environment.
 
CAUSE:
When the report was created with that report filter in the development environment, it is not only the attribute element descriptions (France, Germany, Canada) that are stored as part of the filter definition but also the values of the attribute ID form(s). This means, in the metadata, the report filter definition is stored as:
Region In (France - 9, Germany - 10, Canada - 11)
When generating the SQL, the attribute ID form is used so that the SQL Engine always generates the WHERE clause as:
where a11.[REGION_ID] in (9, 10, 11)
ACTION:
This is working as intended. Strategy does not support elements with changing IDs in an automatic fashion.
 
WORKAROUND:
Consider the following options to work around this issue:

  • Delete and re-create the report filter in the production environment.
  • Qualify on the DESC attribute form for creating filters in the development environment.
  • Make sure the lookup tables in development and production contain identical data.

Comment

0 comments

Details

Knowledge Article

Published:

May 30, 2017

Last Updated:

August 29, 2017