Skip to main content

Posts

Showing posts from September, 2018

The intersection of two subtotals is not calculated when running a report in MicroStrategy

The intersection of two subtotals is not calculated when running a report in MicroStrategy After creating a simple report which displays subtotals in both the columns and rows, users notice that where the subtotals intersect, no data is displayed: However, both substotals are used for the same calculation. In this example, Total calculates the sum of all metrics across columns, and the "Pretty Name" subtotal calculates the sum of all metrics across rows. If the user uses one subtotal object only, instead of two, the values in the intersection are correctly calculated: However, the user wishes to use two different subtotal objects that perform the same calculation so that the name of the subtotal that calculates the sum of all metrics across the rows is different to the name of the subtotal that calculates the sum of all metrics across columns. CAUSE: This is working as designed. The intersection of two different subtotals is not calculated ...

Relative path for images in Microstartegy

Best practices on how to reference an image specified using a relative path for exported documents in MicroStrategy If possible, users should use HTTP paths to reference an image other than relative path or absolute path. If it is necessary to use a relative path to reference image, multiple locations need to store the copy of image as shown in the following table: Important notes: MicroStrategy Web Server is not involved in storing image when exporting. Image should be stored in Intelligence Server or MicroStrategy Developer Client For MicroStrategy Developer export, local MicroStrategy Developer handles the export, image should be placed on every single Developer machine If you don't know your Common Path or MSTR Home Path you can obtain them from the following registry keys if using windows or msireg.reg if using Unix HKEY_LOCAL_MACHINE --> SOFTWARE -->Microstrategy --> DSS Server -> Casetor -->Home Path HKEY_LOCAL_MACHINE --> SO...

Conversion failed when converting the varchar value 'xxxx' Microstartegy

Error "Conversion failed  Error "Conversion failed when converting the varchar value 'xxxx' to data type int" happens when displaying Picture type attribute form using ApplySimple in expression against SQL Server 2012 in MicroStrategy  The attribute form is in Picture type and defined with the following ApplySimple function with Int type column [ID_BARANG] as the input parameter against SQL Server 2012.  Solutions is to use  Concat("Images/demo/s", [BARANG_ID_INT], ".png") ApplySimple("'images/demo/'&#0&'.png'", [ID_BARANG]) However, when running reports with attribute to show the picture form in Web, error message happens in both Web and Developer. Conversion failed when converting the varchar value 'images/demo/s' to data type int. STEPS TO REPRODUCE: SQL Server 2012 database should be used as the warehouse.  Create an attribute form as type Picture and us custom expressi...

Fiscal Week, Fiscal Month, Fiscal Quarter and Fiscal Year calculations in Microstrategy

Fiscal Week, Fiscal Month, Fiscal Quarter and Fiscal Year calculations in Microstrategy FiscalWeek Returns the numeric position of a week within a fiscal year, for a given  input date. This function is useful in financial reporting when the start of the fiscal year is different than the start of the calendar year. Syntax FiscalWeek< firstWeekDay ,  firstMonth >( Date / Time ) Where: • Date / Time  is the input date or timestamp. • firstWeekDay  (default value is 1) is a parameter that determines which day of the week is considered as the first day of the week. You can type an integer value from 1 to 7, with 1 representing Sunday, 2 representing Monday, and so on until 7 representing Saturday. • firstMonth  (default value is 1) is a parameter that determines which month is considered as the start of the fiscal year. You can type an integer value from 1 to 12, with 1 representing January, 2 representing February, and so on until ...

Types of result caches in Microstrategy

Types of result caches Microstrategy The following types of  result caches are created by Intelligence Server: • Matching caches • History caches • Matching-History caches • XML caches All document caches are Matching caches; documents do not generate History caches or XML caches. Intelligent Cube reports do not create Matching caches. Matching caches Matching caches  are the  results of reports and documents that are retained for later use by the same requests later on. In general, Matching caches are the type of result caches that are used most often by Intelligence Server. When result caching is enabled, Intelligence Server determines for each request whether it can be served by an already existing Matching cache. If there is no match, it then runs the report or document on the database and creates a new Matching cache that can be reused if the same request is submitted again. This caching process is managed by the system administrator and ...

Remove the "Layout" tab in a Document in MicroStrategy

Remove the "Layout" tab in a Report Services Document in MicroStrategy In MicroStrategy Web 10.x, when using report services documents, there is a 'Layout' tab on top of the document even when there is only one layout in document, as shown below: ACTION: To remove the tab from being visible, follow these steps: Go to design mode for the document where the 'Layout' tab is no longer desired and under the 'Tools' tab, select the 'Document Properties' option:   A new window will open. Select the 'Advanced' section under 'Document Properties' on the left pane, and make sure to uncheck the option for 'Show single layout tab' under the 'Layout' section as shown below:   Once the option is unchecked, click on the 'Apply' button. The user will now notice that the 'Layout' tab has been removed from view in all document modes:  Note: This option is set on an individual document level.  ...
Using stored procedures within Freeform SQL reports in MicroStrategy Database SQL to Stored Procedure in the DB execute procedure in Freeform Editor in MSTR Microsoft SQL Server CREATE PROCEDURE emp_search @DistCtrID INT as     SET NOCOUNT ON;     SELECT emp_id, emp_first_name + ' ' + emp_last_name     FROM lu_employee     WHERE dist_ctr_id = @DistCtrID; exec sp_ProcedureName @Parameter1= Prompt @Parameter2= Prompt .... ..... After adding the exec procedure statement in Freeform SQL Editor, Add the column for the output columns in the DB stored procedure. https://community.microstrategy.com/s/article/KB37783-Instructions-to-use-stored-procedures-within-Freeform

Case functions Microstrategy

Ca se functions Microstrategy Case functions return specified data in a SQL query based on the evaluation of user-defined conditions. In general, a user specifies a list of conditions and corresponding return values. Case This function evaluates multiple expressions until a condition is determined to be true, then returns a corresponding value. If all conditions are false, a default value is returned.  Case  can be used for categorizing data based on multiple conditions. This is a single-value function. Syntax Case ( Condition1 ,  ReturnValue1 ,  Condition2 , ReturnValue2 ,...,  DefaultValue ) Example Case(([Total Revenue] < 300000), 0, ([Total Revenue] < 600000), 1, 2) sum(Case (Day@DESC in (“Sat”,”Sun”), Sales, 0) {~+} Sum(Case(Category@DESC In("Books","Electronics"),Revenue,0)){~+} CaseV (case vector) CaseV  evaluates a single metric and returns different values according to the results. It can be used to perfo...

"System Prompt" and its uses in MicroStrategy

System Prompt and its uses in MicroStrategy WHAT IS A "SYSTEM PROMPT"? "System Prompt" is a system object that was introduced back in version 8.0.0. The object is named as "User Login" and is implemented as a prompt object. The object can be found under Public Objects > Prompts > System prompts, as shown below: Unlike ordinary prompt objects, system prompts don't require any answers from the user. When a report containing a system prompt runs, the prompt is answered automatically with the login of the user who runs the report. On the other hand, like other prompt objects, answers to system prompts are used to match caches. Therefore, users don't share caches for reports that contain system prompts. For details on how caches are matched, refer to the following MicroStrategy Knowledge Base document: KB5300-7X0-0147 - How are caches matched in MicroStrategy Intelligence Server 7.x? WHEN ARE SYSTEM PROMPTS USED?    System pr...

Best Practices for using images in Microstrategy reports

Using images in Microstrategy reports On the I-Server we copy the images to the following folders: - Program Files (x86)\MicroStrategy\Developer\Images - Program Files (x86)\MicroStrategy\IntelligenceServer\Images - Program Files (x86)\Common Files\MicroStrategy\images To reference an image using relative path, the following locations are required to store the image in order to display in multiple MicroStrategy products.    Relative path sample: images/ logo.jpg To display images on: MicroStrategy Desktop, Web, Mobile, Distribution Services: * Additional Adobe Flash security rule applies when displaying images on Flash Dashboard For image to display on MicroStrategy Web Services:   Note: It is recommended that HTTP path should be used for reference image. User should consider using HTTP path to reference image and store image in an client accessible server for easier maintain and upgrading purpose ...