Skip to Content
avatar image
Former Member

how to make a good hour time with colon display

We have in our table, the datetime is only holding the date. There is also an hour col and a minute col, there are for the appointment. the are both columns defined as number.

The hour is typically like this: 12.00 and minutes as well like 45.00

I would like make a formula that will contain '12:45'.

I tried to combine the 2 columns but it added them. ({DDB_APPT_BASE.TIME_HOUR} + {DDB_APPT_BASE.TIME_MINUTE})

I put quotes there but it just brings the name itself.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Aug 22, 2017 at 09:33 PM

    Hi Paul,

    Create a formula with this code:

    Time({DDB_APPT_BASE.TIME_HOUR}, {DDB_APPT_BASE.TIME_MINUTE}, 00)

    -Abhilash

    Add comment
    10|10000 characters needed characters exceeded

  • Aug 22, 2017 at 09:39 PM

    Hi Paul,

    You can use the Time function like:

    Time ({DDB_APPT_BASE.TIME_HOUR}, {DDB_APPT_BASE.TIME_MINUTE}, 0); 

    Then you can format the formula in the time format you want.

    If you want it as a string, use the ToText format and concatenate the hours, colon and minutes like:

    ToText ({DDB_APPT_BASE.TIME_HOUR}, 0, "", "") & ":" & ToText ({DDB_APPT_BASE.TIME_MINUTE}, 0, "", ""); 

    Good luck,

    Brian

    Add comment
    10|10000 characters needed characters exceeded