cancel
Showing results for
Did you mean:
Anonymous
Not applicable

## Handling infinity value

Hello,

I am currently using a measure to calculate Sales Rate. The calculation is as follows FactTable[X]/FactTable[Y]. The X and Y come from different Fact tables. If Y is not present for the corresponding date, I am getting a value of infinity. It would be good to have nothing show up then to have infinity value. How do I achieve this?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi,

I got a solution online before I came across your post. Refer below for the solution.

```IFERROR(
[Mesaure 1]/[Mesaure 2],
BLANK()
)```

where Mesaure 1 is Sum(FactTable[x])and Mesaure 2 is Sum(FactTable[y])

Found it in this blog- https://sqldusty.com/

4 REPLIES 4

Found this alternative without getting 'Cannot load Visual Error', DIVIDE function

DIVIDE(numerator,denominator,0)

Responsive Resident

If FactTable[Y] is zero just display blank for example:

Measure = IF(FactTable[Y]=0,BLANK(),FactTable[X]/FactTable[Y])

Anonymous
Not applicable

Hi,

I got a solution online before I came across your post. Refer below for the solution.

```IFERROR(
[Mesaure 1]/[Mesaure 2],
BLANK()
)```

where Mesaure 1 is Sum(FactTable[x])and Mesaure 2 is Sum(FactTable[y])

Found it in this blog- https://sqldusty.com/

IF Error calculation does work, however it takes a load on the memory and fails with 'cannot load visual' error. Is there an alternative to avoid this issue?

Announcements

#### The Power BI Community Show

Welcome to the Power BI Community Show! Jeroen ter Heerdt talks about the importance of Data Modeling.

#### Charticulator Design Challenge

Put your data visualization and design skills to the test! This exciting challenge is happening now through June10th!

#### Check it Out!

Watch Session 22 Ted's Dev Camp along with past sessions!