How to format date inside a table

Configure the .props.columns list for your table to call out each column and provide datatype and rendering information:

https://docs.inductiveautomation.com/display/DOC81/Perspective+-+Table#PerspectiveTable-Properties

https://docs.inductiveautomation.com/display/DOC81/Table+Column+Configurations

Some background:

The datetime information in your database and the datatime datatypes in Ignition travel around the system as objects, and in Ignition, are timezoneless (UTC) milliseconds under the hood (java.util.Date objects, to be specific). They are only converted to strings for display.

Unfortunately, the javascript language used in browsers doesn't actually have this kind of object, so Ignition transmits the underlying UTC milliseconds to Perspective clients. Ignition's various Perspective UI components know how to display these as date/time strings when told to.

In the rare case when you need to convert to strings yourselves, there are hoops to jump through. See this topic for typical solutions:

3 Likes