Join us at Snowflake Summit June 26-29 in Las Vegas!

Any Function Added to the Rel Standard Library

George Kastrinis

06 October 2021

less than a minute read

The Standard Library now offers the Any function. This is a unary relation that is true for any value used. It is used as a generic type assertion that always succeeds.

In the following example, we define a relation R that contains tuples of various lengths (arities). In the second line we output the second argument of all the tuples in R that have arity 3. By using Any in the first and third position, we declare that we are not interested in the values of these arguments:

def R = {(1, 2, 3); ("a", 3, 0.5); (11, 22, 33, 44)}

def output = x : R(Any, x, Any)



Related Posts

Get Early Access

Join our community, keep up to date with the latest developments in our monthly newsletter, and get early access to RelationalAI.