Time expression help

I need to formulate

if( time > 12 PM, use “[time]&AM”, use"[Time]-12"&PM)

I’m using this:

if(
[Start Time]-12:00>0, concatenate([Start Time], " AM"), concatenate(([Start Time]-12), " PM"))

I’m being shown:

Arithmetic expression ‘(([Start Time]-“12:00”) > 0)’ does not have valid input types

What exactly do I have to change here?

0 1 123
1 REPLY 1

You may wish to mention where the field [Start Time] is used? And what type of the field is and where it is - detail view etc.

In general, an expression could be constructed for your requirement. It sounds that you are trying to convert 24 hr time format into 12 hr. However the expression needs to work in all devices and views etc.

The date time values are dependent on date time settings in at least three four places (spreadsheet, browser locale) and finally mainly the date time setting in the user device and as such maybe you wish to elaborate on the need for this expression. Or else the expression may work in one device or view but not in the other.

Top Labels in this Space