cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • JMP will suspend normal business operations for our Winter Holiday beginning on Wednesday, Dec. 24, 2025, at 5:00 p.m. ET (2:00 p.m. ET for JMP Accounts Receivable).
    Regular business hours will resume at 9:00 a.m. EST on Friday, Jan. 2, 2026.
  • We’re retiring the File Exchange at the end of this year. The JMP Marketplace is now your destination for add-ins and extensions.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
UserID16644
Level V

Adding dates from columns

I have 3 dates that I wanted to add up in order to calculate the total number of days. Is there a way to do this? I just know the Date Difference ( ) function, but doesn't know if there is a function used in calculating the sum of dates from three different columns? 

4 REPLIES 4
Jeff_Perkinson
Community Manager Community Manager

Re: Adding dates from columns

Adding dates is an interesting concept.

Can you explain exactly what you mean?

I’m trying to guess what April 3, 2022 + May 22, 2022 would be.
-Jeff
UserID16644
Level V

Re: Adding dates from columns

Yes, so the sum would be how many days does April 3-May 22 have

txnelson
Super User

Re: Adding dates from columns

Here is a simple example:

Names Default To Here( 1 );
date1 = informat("4/3/2023");
date2 = informat("5/22/2023");
Date Difference(
	Date1,
	Date2,
	"Day",
	"start"
);
Jim
Jeff_Perkinson
Community Manager Community Manager

Re: Adding dates from columns

That helps. The Date Difference() function will tell you the number of days between two dates.

 

//:*/
start = 03Apr2022;
end = 22May2022;
days = Date Difference( start, end, "Day" );
/*:

49

You said something about a third date. How will that be used?

 

For more information you might find Using dates, times, datetimes and durations in JMP useful.

-Jeff

Recommended Articles