For the complete documentation index, see llms.txt. This page is also available as Markdown.

lcm

This section contains reference documentation for the lcm function.

Returns the least common multiple of two long values. Returns 0 if either input is 0.

Signature

lcm(col1, col2)

Argument
Type
Description

col1

LONG

First value

col2

LONG

Second value

Returns: LONG

Usage Examples

SELECT lcm(4, 6) AS value
FROM myTable
value

12

SELECT lcm(0, 5) AS value
FROM myTable
value

0

Last updated

Was this helpful?