Converting seconds to time format

Hello there, Today let's talk about a quick tip: how to transform seconds to hh:mm or even hh:mm:ss. You just have to: Create a new metric using your seconds metric and divide it by 86400. Example of the formula would be: [metric with seconds] / 86400 2. Format the number to be like [h]:mm or [h]:mm:ss …

Using a “case” function multiple times

Hello there, Today a quick tip about how use the case MicroStrategy function multiple times. To do that you just have to: Create a metric Add an expression like this: Case(([metric] = 1),'true', ([metric] = 2), 'true', 'false') Blue: The condition Green: When the condition is true False: When the condition is false This way, you can …

Number format in MicroStrategy

Hello there! My friend Diogo Martins, told me a simple but powerful custom formatting to numbers that can help you so much! Here is the tip: Think that you have a Profit metric with a number like this: 1.304.141 And you want to divide that by 1000. You just have to: Format the value and go to …

Adaptive Metrics

Hello there! Today let's talk about how to create different aggregation formula for each fact table used in a fact in Microstrategy. Let's say that we need to create a SUM(value) for Fact A and a COUNT(value) for Fact B. When we get data from Fact A, Microstrategy must SUM, when in Fact B, Microstrategy must COUNT. …

How to show the parameters set in metrics

Hello there! Today I'm going to teach you a quick tip that can help you see the parameters that were set in a metric. The default behavior of MicroStrategy is the hide all parameters set for your metrics. it's much better to see everything that you are using. To do that you just have to: 1. Open Developer/Desktop …

Adding filter in a Derived Metric

Hello there! Today let's talk about an excellent trick with derived metrics. There is a way to insert a filter in your derived metric! Let me show you an example: 1. Create a filter with Year = 2010 and save your filter as "2010": 2. Create a blank report with Year and the metric Cost: …

Changing Metric Column Alias Name

Hello there! Today let's talk about changing the metric alias name in the SQL that MicroStrategy generates. Sometimes you need to debug the query and you see something like this: select name_pu as name, sum(salary) as #MAS01MQW from Fact_Table group by name_pu If you have a lot of metric inside your report, it is very …