YEARFRAC Error in calcualation.

Mavericks334

Active Member
Joined
Jan 26, 2011
Messages
280
Hi,

I have two columns that give me the dates.

I am using YearFRAC to calculate the difference in years.

[TABLE="width: 116"]
<COLGROUP><COL style="WIDTH: 62pt; mso-width-source: userset; mso-width-alt: 3035" width=83><COL style="WIDTH: 54pt; mso-width-source: userset; mso-width-alt: 2633" width=72><TBODY>[TR]
[TD="class: xl74, width: 83, bgcolor: #92cddc"]Joining Date[/TD]
[TD="class: xl74, width: 72, bgcolor: #92cddc"]MonthEnd[/TD]
[/TR]
[TR]
[TD="class: xl75, bgcolor: #dce6f1, align: right"]4/6/2001[/TD]
[TD="class: xl75, bgcolor: #dce6f1, align: right"]5/31/2013[/TD]
[/TR]
[TR]
[TD="class: xl75, bgcolor: #dce6f1, align: right"]8/1/2009[/TD]
[TD="class: xl75, bgcolor: #dce6f1, align: right"]5/31/2013[/TD]
[/TR]
</TBODY>[/TABLE]


When i use the formual in excel it works fine for both the data points. However when i use it in powerpivot i get and error for the 1st data point. Any suggestions how i could avoid this error.

Regards,
Ren.
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.

Forum statistics

Threads
1,223,950
Messages
6,175,584
Members
452,653
Latest member
craigje92

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top