1.1.1

Table Of Contents
The type's comparison rules determine the minimum value. For CHAR and VARCHAR, the number of blank
spaces at the end of the value can affect how MIN is evaluated. For example, if the values 'z' and 'z ' are both
stored in a column, you cannot control which one will be returned as the minimum, because blank spaces are
ignored for character comparisons.
The resulting data type is the same as the expression on which it operates (it will never overow).
Examples
-- NOT valid:
SELECT DISTINCT flying_time, MIN(DISTINCT miles) from Flights
-- valid:
SELECT COUNT(DISTINCT flying_time), MIN(DISTINCT miles) from
Flights
-- find the earliest date:
SELECT MIN (flight_date) FROM FlightAvailability;
MINUTE function
The MINUTE function returns the minute part of a value.
The argument must be a time, timestamp, or a valid character string representation of a time or timestamp that
is not a CLOB, LONG VARCHAR, or XML value. The result of the function is an integer between 0 and 59.
If the argument can be null, the result can be null; if the argument is null, the result is the null value.
Syntax
MINUTE ( expression )
Example
Select all rows from the "ights" table where the "departure_time" is between 6:00 and
6:30 AM:
SELECT * FROM flights
WHERE HOUR(departure_time) = 6 and MINUTE(departure_time)
< 31;
MOD function
MOD returns the remainder (modulus) of argument 1 divided by argument 2. The result is negative only if
argument 1 is negative.
Syntax
mod(integer_type, integer_type)
The result of the function is:
SMALLINT if both arguments are SMALLINT.
INTEGER if one argument is INTEGER and the other is INTEGER or SMALLINT.
BIGINT if one integer is BIGINT and the other argument is BIGINT, INTEGER, or SMALLINT.
The result can be null; if any argument is null, the result is the null value.
MONTH function
The MONTH function returns the month part of a value.
vFabric SQLFire User's Guide578
vFabric SQLFire Reference