Package org.apache.calcite.sql
Enum JoinType
- All Implemented Interfaces:
Serializable
,Comparable<JoinType>
,Constable
,Symbolizable
Enumerates the types of join.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionAn ASOF JOIN operation combines rows from two tables based on comparable timestamp values.Comma join: the good old-fashioned SQLFROM
clause, where table expressions are specified with commas between them, and join conditions are specified in theWHERE
clause.Cross join (also known as Cartesian product).Full outer join.Inner join.Left outer join.Left anti join.The left version of an ASOF join, where each row from the left table is part of the output.Left semi join.Right outer join. -
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Returns whether a join of this type may generate NULL values on the left-hand side.boolean
Returns whether a join of this type may generate NULL values on the right-hand side.static JoinType
Returns the enum constant of this type with the specified name.static JoinType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.Methods inherited from class java.lang.Enum
clone, compareTo, describeConstable, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
Methods inherited from interface org.apache.calcite.sql.Symbolizable
symbol
-
Enum Constant Details
-
INNER
Inner join. -
FULL
Full outer join. -
CROSS
Cross join (also known as Cartesian product). -
LEFT
Left outer join. -
RIGHT
Right outer join. -
LEFT_SEMI_JOIN
Left semi join.Not used by Calcite; only in Babel's Hive dialect.
-
LEFT_ANTI_JOIN
Left anti join.Not used by Calcite; only in Babel's Spark dialect.
-
COMMA
Comma join: the good old-fashioned SQLFROM
clause, where table expressions are specified with commas between them, and join conditions are specified in theWHERE
clause. -
ASOF
An ASOF JOIN operation combines rows from two tables based on comparable timestamp values. For each row in the left table, the join finds at most one row in the right table that has the "closest" timestamp value. The matched row on the right side is the closest match, which could less than or equal or greater than or equal in the timestamp column, as specified by the comparison operator.Example:
FROM left_table ASOF JOIN right_table MATCH_CONDITION ( left_table.timecol ≤ right_table.timecol ) ON left_table.col = right_table.col
-
LEFT_ASOF
The left version of an ASOF join, where each row from the left table is part of the output.
-
-
Field Details
-
lowerName
Lower-case name.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
generatesNullsOnLeft
public boolean generatesNullsOnLeft()Returns whether a join of this type may generate NULL values on the left-hand side. -
generatesNullsOnRight
public boolean generatesNullsOnRight()Returns whether a join of this type may generate NULL values on the right-hand side.
-