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

KB36681: Null check not being applied in HAVING clause in MicroStrategy Developer 9.4.1 and 10.x.


Stefan Zepeda

Salesforce Solutions Architect • Strategy


In MicroStrategy Developer 9.4.1 and 10.x, users notice that Null checks are ignored in the HAVING clause when the VLDB property "change the Additional Final Pass Option" is set to "One additional final pass only to join lookup tables".

SYMPTOM:
In Strategy Developer 9.4.1 and 10.x, users notice that Null checks are ignored in the HAVING clause when the VLDB property "change the Additional Final Pass Option" is set to "One additional final pass only to join lookup tables".
 
STEPS TO REPRODUCE:

  1.  In the Tutorial project within Strategy Developer, create a metric with the following definition: (Cost + Profit)
  2. Make sure the metric created in step 1 is not a smart metric.
  3. Create a report with the attributes Year, Quarter, Region and the metric from step 1 on the report template.
  4. Add a report limit setting the metric created in step 1 greater than zero.
  5. Under the VLDB properties for the report, change the Additional Final Pass Option setting to One additional final pass only to join lookup tables.
  6. Under the VLDB properties for the report, change the Null Checksetting to Check for NULL in all queries.

Running the report will yield the following SQL:
 


create view ZZEA00 (QUARTER_ID, REGION_ID, WJXBFS1) as

select a12.QUARTER_ID AS QUARTER_ID,

 a13.REGION_ID AS REGION_ID,

 (COALESCE(sum(a11.TOT_COST), 0) + COALESCE(sum((a11.TOT_DOLLAR_SALES - a11.TOT_COST)), 0)) AS WJXBFS1

from DAY_CTR_SLS a11,

 LU_DAY a12,

 LU_CALL_CTR a13

where a11.DAY_DATE = a12.DAY_DATE and

 a11.CALL_CTR_ID = a13.CALL_CTR_ID

group by a12.QUARTER_ID,

 a13.REGION_ID

having (sum(a11.TOT_COST) + sum((a11.TOT_DOLLAR_SALES - a11.TOT_COST))) > 0.0

 
*Note that the "having" clause does not contain the COALESCE function.
 
CAUSE:
This is a known issue in Strategy 9.4.1 and 10.x.
 
ACTION:
Currently this issue is still being reviewed for feasibility by our Technology team and it is not scoped for any upcoming scheduled Strategy release.
 
 
 


Comment

0 comments

Details

Knowledge Article

Published:

June 16, 2017

Last Updated:

June 16, 2017