Forum Discussion

sokatenaj's avatar
sokatenaj
Advocate II
9 years ago
Solved

Visual just stopped working...

Hi Folks,

 

The same PeopleSoft query runs every day and there has not been any change to it. The "Birth Date" field in that query is a Date field. When I opened my Power BI file today to refresh the data, I got this error on a visual:

  I have not made one change to the visual, Power BI file, or PeopleSoft feed in two weeks and this just magically popped up today. 

 

I have a calculated colum giving me the retirement date which is:

 

Retirement Date =
SWITCH (
TRUE (),
YEAR ( 'Active EEs'[Birth Date]) >= 1937
&& YEAR ( 'Active EEs'[Birth Date] ) <= 1942,
(
DATE ( ( YEAR ( [Birth Date] ) + 65 ), MONTH ( 'Active EEs'[Birth Date] ), DAY ( 'Active EEs'[Birth Date] ) )
), YEAR ( 'Active EEs'[Birth Date] ) >= 1942
&& YEAR ( 'Active EEs'[Birth Date] ) <= 1959,
(
DATE ( ( YEAR ( [Birth Date] ) + 66 ), MONTH ( 'Active EEs'[Birth Date] ), DAY ( 'Active EEs'[Birth Date] ) )
),
(
DATE ( ( YEAR ( [Birth Date] ) + 67 ), MONTH ( 'Active EEs'[Birth Date] ), DAY ( 'Active EEs'[Birth Date] ) )
)
)

 

My retirement eligibility calculated column is also messed up because of the above measure. The measure for retirement eligibility is:

 

Retirement Eligibility = SWITCH ( TRUE (), TODAY () > 'Active EEs'[Retirement Date], "Over retirement", 'Active EEs'[Retirement Date] <= DATE (( YEAR ( TODAY () ) + 3), MONTH ( TODAY () ), DAY ( TODAY () ) ), "Within 3 Years", 'Active EEs'[Retirement Date] <= DATE (( YEAR ( TODAY () ) + 5), MONTH ( TODAY () ), DAY ( TODAY () ) ), "Within 5 Years", "Not Eligible" )

 

What the heck would make this just stop working? All I do is click "refresh" and publish. 

 

Any help would be appreciated! Many thanks!!!

  • Nevermind. I found out what the error was. We have someone that started working that was born in 1922 and my measure started at 1937 so it didn't know what to do...

1 Reply

  • Nevermind. I found out what the error was. We have someone that started working that was born in 1922 and my measure started at 1937 so it didn't know what to do...