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

KB15499: How to extract month name that is stored as a numerical field in the warehouse in MicroStrategy Developer 10.x


Stefan Zepeda

Salesforce Solutions Architect • Strategy


This article explains how to extract an attribute name that is stored as a numerical field in the warehouse in MicroStrategy Developer 10.x

When using a warehouse that has a table storing month values only as a number, users wish to also display the corresponding month names in Strategy Developer 10.x. The month names do not originally reside in the warehouse tables and the user does not want to manually input the values into the warehouse. The following will detail how to accomplish this task without manual data entry into the warehouse.
 
NOTES:

  1. These steps are used to setup the month name based off an integer value within the Strategy Tutorial project. The case statements may differ depending on database being used; this is an implementation on SQL Server.
  2. An attribute ID form storing the numerical 1 through 12 representations of months is necessary in order to apply the appropriate sorting of values based on the month name.

To display the corresponding month names, follow the steps below in the Strategy Tutorial project:
 

  • Create a new attribute with ID form mapping to , as shown below:
ka02R000000kc20QAA_0EM440000002FI3.jpeg
  • Create a new DESC form with the following ApplySimple statement:
ka02R000000kc20QAA_0EM440000002FHz.jpeg
  •  
    ApplySimple("Case when #0 = 1 then 'January' when #0 = 2 then 'February' when #0 = 3 then 'March' when #0 = 4 then 'April' when #0 = 5 then 'May' when #0 = 6 then 'June' when #0 = 7 then 'July' when #0 = 8 then 'August' when #0 = 9 then 'September' when #0 = 10 then 'October' when #0 = 11 then 'November' when #0 = 12 then 'December' END", )
  • Set to manual mapping and map to the LU_MONTH and LU_MONTH_OF_YEAR tables and form format to Number, as shown below:
ka02R000000kc20QAA_0EM440000002FHp.jpeg
  • Update Schema
  • Create a new report and place the newly created attribute in the grid.

The following is a representation of the month attribute created above within a report. The attribute is named "Month Number" and the DESC and ID forms are being displayed.
 

ka02R000000kc20QAA_0EM440000002FI5.jpeg

 


Comment

0 comments

Details

Knowledge Article

Published:

June 1, 2017

Last Updated:

June 1, 2017