Forum Discussion

supr4's avatar
supr4
Frequent Visitor
4 years ago
Solved

Help recreating excel sample formula in Power Bi

Hello,

As the tittle says, I'm having issues with the mentioned task.

FormulaApplied formula result

 

 

 

 

 

 

The column 'Otros' and 'Total Gen' are the ones I can't replicate.

Any help would be amazing,
thanks beforehand for any answer.

  • Hi supr4

     

    Create calculated columns as:

     

    f>12meses… = 
    IF(
        'Table 1'[Rango]="f>12meses…",
        'Table 1'[Stocks/],
        BLANK()
    )
    d.6-9meses = 
    IF(
        'Table 1'[Rango]="d.6-9meses",
        'Table 1'[Stocks/],
        BLANK()
    )
    Otros = 
    'Table 1'[Stocks/]-'Table 1'[f>12meses…]-'Table 1'[d.6-9meses]
    Total Gen = 
    'Table 1'[f>12meses…]+'Table 1'[Otros]

     

    Here is the output:

    The demo is attached, please try it.

     

    If you still have some question, please don't hesitate to let me known.‌‌

     

    Best Regards,

    Link

     

    Is that the answer you're looking for? If this post helps, then please consider Accept it as the solution. Really appreciate!

     

2 Replies

  • v-xulin-mstf's avatar
    v-xulin-mstf
    Community Support

    Hi supr4

     

    Create calculated columns as:

     

    f>12meses… = 
    IF(
        'Table 1'[Rango]="f>12meses…",
        'Table 1'[Stocks/],
        BLANK()
    )
    d.6-9meses = 
    IF(
        'Table 1'[Rango]="d.6-9meses",
        'Table 1'[Stocks/],
        BLANK()
    )
    Otros = 
    'Table 1'[Stocks/]-'Table 1'[f>12meses…]-'Table 1'[d.6-9meses]
    Total Gen = 
    'Table 1'[f>12meses…]+'Table 1'[Otros]

     

    Here is the output:

    The demo is attached, please try it.

     

    If you still have some question, please don't hesitate to let me known.‌‌

     

    Best Regards,

    Link

     

    Is that the answer you're looking for? If this post helps, then please consider Accept it as the solution. Really appreciate!

     

  • Please provide sample data in usable format (not as a picture - maybe insert into a table?) and show the expected outcome.  Trying to recreate Excel formulas does a disservice to the capabilities of Power BI.