Product Documentation

SQL Reference Guide

Previous Topic

Next Topic

HOUR function (ODBC compatible)

Syntax

HOUR ( time_expression )

Description

The scalar function HOUR returns the hour in the argument as a short integer value in the range of 0 - 23.

Example

SELECT *

FROM arrivals

WHERE HOUR (in_time) < 12 ;

Notes

  • The argument to the function must be of type TIME.
  • The argument must be specified in the format hh:mi:ss.
  • The result is of type SHORT.
  • If the argument expression evaluates to null, the result is null.

TOCIndex