cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Don’t miss your chance to experience Discovery Summit Europe at our best available rate! Early bird registration through 31 Oct.
  • Image to Table JMP extension imports single or batch images as data tables. Useful to extract curves from pictures or convert image data to curve data to use in analyses like Functional Data Explorer. Download and install the extension.

Discussions

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

Creating a column and Filling all rows by a date and time

I Want to create a column named, say, :CHANGE and then fill all rows by a date in the format 01/15/2026 7:02:26 PM. How do I do that. 

For some reason JSL does not recognize this format

1 ACCEPTED SOLUTION

Accepted Solutions
jthi
Super User

Re: Creating a column and Filling all rows by a date and time

In my opinion only reliable way to format your dates to specific format in JMP (while keeping them as numeric) is to use Format Pattern

Names Default To Here(1);

dt = New Table("Untitled",
	Add Rows(7),
	Compress File When Saved(1)
);

dt << New Column("CHANGE", Numeric, Continuous, Format("Format Pattern", "<MM>/<DD>/<YYYY> <hh>:<mm>:<ss><AMPM>", 21, 0), Set Each Value(
	15Jan202619:02:27
));

JSL Syntax Reference > JSL Functions, Operators, and Messages > Date and Time Functions 

Using JMP > Set JMP Column Properties > About the Column Info Window > Numeric Formats 

-Jarmo

View solution in original post

2 REPLIES 2
jthi
Super User

Re: Creating a column and Filling all rows by a date and time

In my opinion only reliable way to format your dates to specific format in JMP (while keeping them as numeric) is to use Format Pattern

Names Default To Here(1);

dt = New Table("Untitled",
	Add Rows(7),
	Compress File When Saved(1)
);

dt << New Column("CHANGE", Numeric, Continuous, Format("Format Pattern", "<MM>/<DD>/<YYYY> <hh>:<mm>:<ss><AMPM>", 21, 0), Set Each Value(
	15Jan202619:02:27
));

JSL Syntax Reference > JSL Functions, Operators, and Messages > Date and Time Functions 

Using JMP > Set JMP Column Properties > About the Column Info Window > Numeric Formats 

-Jarmo
NewToThis
Level III

Re: Creating a column and Filling all rows by a date and time

Can't thank you enough for this. Thanks

Recommended Articles