public class TExpression extends TParseTreeNode
getExpressionType()
was used to distinguish these types.
OBJECT NAME/CONSTANT/SOURCE TOKEN/FUNCTION CALL
EExpressionType.simple_object_name_t
getObjectOperand()
EExpressionType.simple_constant_t
getConstantOperand()
EExpressionType.simple_source_token_t
getSourcetokenOperand()
EExpressionType.function_t
getFunctionCall()
EExpressionType.unary_plus_t
getOperatorToken()
EExpressionType.unary_minus_t
getOperatorToken()
EExpressionType.unary_factorial_t
getLeftOperand()
getOperatorToken()
EExpressionType.unary_bitwise_not_t
getRightOperand()
getOperatorToken()
EExpressionType.unary_absolutevalue_t
getRightOperand()
getOperatorToken()
EExpressionType.unary_squareroot_t
getRightOperand()
getOperatorToken()
EExpressionType.unary_cuberoot_t
getRightOperand()
getOperatorToken()
EExpressionType.unary_factorialprefix_t
getRightOperand()
getOperatorToken()
EExpressionType.unary_prior_t
getOperatorToken()
EExpressionType.unary_connect_by_root_t
getOperatorToken()
EExpressionType.unary_prior_t
getOperatorToken()
EExpressionType.arithmetic_plus_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.arithmetic_minus_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.arithmetic_times_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.arithmetic_divide_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.arithmetic_modulo_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.exponentiate_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.arithmetic_compound_operator_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.logical_and_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.logical_or_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.logical_xor_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.logical_not_t
getRightOperand()
getOperatorToken()
EExpressionType.assignment_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.concatenate_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.at_time_zone_t
getLeftOperand()
getRightOperand()
EExpressionType.at_local_t
getLeftOperand()
EExpressionType.bitwise_and_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.bitwise_or_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.bitwise_exclusive_or_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.bitwise_xor_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.bitwise_shift_left_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.bitwise_shift_right_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.subquery_t
getSubQuery()
EExpressionType.parenthesis_t
getLeftOperand()
TParseTreeNode.getStartToken()
to get ( and TParseTreeNode.getEndToken()
to get )EExpressionType.list_t
getExprList()
, may return null when expression list in syntax like this: () TParseTreeNode.getStartToken()
,
close parenthesis ) can be fetched via TParseTreeNode.getEndToken()
EExpressionType.collection_constructor_set_t
EExpressionType.collection_constructor_multiset_t
EExpressionType.collection_constructor_list_t
getExprList()
, may return null when expression list in syntax like this: () EExpressionType.simple_comparison_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.group_comparison_t
getLeftOperand()
getRightOperand()
getOperatorToken()
getQuantifier()
EExpressionType.in_t
getLeftOperand()
getRightOperand()
getOperatorToken()
getNotToken()
EExpressionType.case_t
getCaseExpression()
}EExpressionType.cursor_t
getSubQuery()
TParseTreeNode.getStartToken()
EExpressionType.pattern_matching_t
getLeftOperand()
getRightOperand()
getLikeEscapeOperand()
getOperatorToken()
getNotToken()
getQuantifier()
EExpressionType.null_t
getLeftOperand()
getOperatorToken()
getNotToken()
EExpressionType.between_t
getBetweenOperand()
getLeftOperand()
getRightOperand()
getOperatorToken()
getNotToken()
EExpressionType.exists_t
getSubQuery()
TParseTreeNode.getStartToken()
EExpressionType.is_unknown_t
getLeftOperand()
getOperatorToken()
getNotToken()
EExpressionType.is_true_t
getLeftOperand()
getOperatorToken()
getNotToken()
EExpressionType.is_false_t
getLeftOperand()
getOperatorToken()
getNotToken()
EExpressionType.day_to_second_t
getLeftOperand()
EExpressionType.year_to_month_t
getLeftOperand()
EExpressionType.interval_t
getIntervalExpr()
EExpressionType.new_structured_type_t
getFunctionCall()
EExpressionType.new_variant_type_t
getNewVariantTypeArgumentList()
EExpressionType.new_variant_type_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.new_variant_type_t
getLeftOperand()
getOperatorToken()
getNotToken()
EExpressionType.left_shift_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.right_shift_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.is_document_t
getLeftOperand()
getOperatorToken()
getNotToken()
EExpressionType.is_distinct_from_t
getLeftOperand()
getRightOperand()
getOperatorToken()
getNotToken()
EExpressionType.left_join_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.right_join_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.collate_t
getLeftOperand()
getRightOperand()
getOperatorToken()
getNotToken()
EExpressionType.member_of_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.next_value_for_t
getSequenceName()
getOver_clause()
} getLeftOperand()
EExpressionType.ref_arrow_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.typecast_t
getTypeName()
getLeftOperand()
getOperatorToken()
EExpressionType.multiset_t
getSubQuery()
TParseTreeNode.getStartToken()
EExpressionType.floating_point_t
getLeftOperand()
getOperatorToken()
getNotToken()
EExpressionType.row_constructor_t
getExprList()
TParseTreeNode.getStartToken()
EExpressionType.is_of_type_t
getLeftOperand()
EExpressionType.place_holder_t
EExpressionType.type_constructor_t
getFunctionCall()
EExpressionType.arrayaccess_t
getArrayAccess()
EExpressionType.object_access_t
getObjectAccess()
EExpressionType.unknown_t
getLeftOperand()
getRightOperand()
getOperatorToken()
EExpressionType.unary_left_unknown_t
getRightOperand()
getOperatorToken()
EExpressionType.unary_right_unknown_t
getLeftOperand()
getOperatorToken()
like this: ARRAY[1,2,3+4]
array element values can be accessed via getExprList()
,
or getExprList()
can be null when it is: array[]
It is also possible to construct an array from the results of a subquery like this:
SELECT ARRAY(SELECT oid FROM pg_proc WHERE proname LIKE 'bytea%');
thus, subquery can be access via getSubQuery()
EExpressionType.array_constructor_t
getExprList()
getSubQuery()
expression.fieldname
In general the row expression must be parenthesized, but the parentheses can be omitted
when the expression to be selected from is just a table reference or positional parameter.
For example:
mytable.mycolumn
$1.somecolumn
(rowfunction(a,b)).col3
(Thus, a qualified column reference is actually just a special case of the field selection syntax.) An important special case is extracting a field from a table column that is of a composite type:
(compositecol).somefield
(mytable.compositecol).somefield
The parentheses are required here to show that compositecol is a column name not a table name,
or that mytable is a table name not a schema name in the second case.
n a select list, you can ask for all fields of a composite value by writing .*:
(compositecol).*
When expression in following syntax, it will be marked as fieldSelection
, and check getFieldName()
(rowfunction(a,b)).col3
(compositecol).somefield
(mytable.compositecol).somefield
(compositecol).*
Otherwise, it will be marked as simpleObjectname
:
mytable.mycolumn
$1.somecolumn
EExpressionType.fieldselection_t
EExpressionType.array_access_expr_t
getLeftOperand()
getRightOperand()
EExpressionType.object_access_t
getLeftOperand()
getFieldList()
EExpressionType.json_get_object
getLeftOperand()
getLeftOperand()
EExpressionType.json_get_text
getLeftOperand()
getLeftOperand()
EExpressionType.json_get_object_at_path
getLeftOperand()
getLeftOperand()
EExpressionType.json_get_text_at_path
getLeftOperand()
getLeftOperand()
EExpressionType.json_left_contain
getLeftOperand()
getLeftOperand()
EExpressionType.json_right_contain
getLeftOperand()
getLeftOperand()
EExpressionType.json_exist
getLeftOperand()
getLeftOperand()
EExpressionType.json_any_exist
getLeftOperand()
getLeftOperand()
EExpressionType.json_all_exist
getLeftOperand()
getLeftOperand()
EExpressionType.is_a_set_t
getLeftOperand()
EExpressionType.array_t
getExprList()
getTypeName()
returns the T of this Array if specified.Modifier and Type | Field and Description |
---|---|
static int |
absoluteValue
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_absolutevalue_t |
static int |
arrayaccess
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.arrayaccess_t |
static int |
arrayConstructor
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.array_constructor_t |
static int |
ASSIGNMENT
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.assignment_t |
static int |
at_local
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.at_local_t |
static int |
at_time_zone
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.at_time_zone_t |
static int |
between_conditions
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.between_t |
static int |
BigAndOrNestLevel |
static int |
BITWISE_AND
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.bitwise_and_t |
static int |
BITWISE_EXCLUSIVE_OR
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.bitwise_exclusive_or_t |
static int |
BITWISE_NOT
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_bitwise_not_t |
static int |
BITWISE_OR
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.bitwise_or_t |
static int |
BITWISE_SHIFT_LEFT
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.bitwise_shift_left_t |
static int |
BITWISE_SHIFT_RIGHT
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.bitwise_shift_right_t |
static int |
BITWISE_XOR
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.bitwise_xor_t |
static int |
caseExprOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.case_t |
static int |
COLLATE
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.collate_t |
static int |
compoundAssignment
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.arithmetic_compound_operator_t |
static int |
compoundParenthesis
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.parenthesis_t |
static int |
compoundPrior
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_prior_t |
static int |
compoundUnaryBitwiseNot
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_bitwise_not_t |
static int |
compoundUnaryMinus
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_minus_t |
static int |
compoundUnaryPlus
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_plus_t |
static int |
CONCATENATE
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.concatenate_t |
static int |
connect_by_root
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_connect_by_root_t |
static int |
cubeRoot
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_cuberoot_t |
static int |
cursorExprOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.cursor_t |
static int |
datetimeExprOperator
Deprecated.
As of v1.4.3.0
|
static int |
day_to_second
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.day_to_second_t |
static int |
DIVIDE
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.arithmetic_divide_t |
static int |
dummyOperator
Deprecated.
As of v1.4.3.0
|
static int |
exists_condition
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.exists_t |
static int |
EXPONENTIATE
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.exponentiate_t |
static int |
expr_list
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.list_t |
static int |
factorial
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_factorial_t |
static int |
factorialPrefix
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_factorialprefix_t |
static int |
fieldSelection
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.fieldselection_t |
static int |
floating_point_conditions
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.floating_point_t |
static int |
funcationCallOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.function_t |
static int |
group_comparison_conditions
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.group_comparison_t |
static int |
in_conditions
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.in_t |
static int |
in_expr
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.group_t |
static int |
interval_expression
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.interval_t |
static int |
intervalExprOperator
Deprecated.
As of v1.4.3.0
|
static int |
is_distinct_from
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.is_distinct_from_t |
static int |
is_document
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.is_document_t |
static int |
isoftype_condition
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.is_of_type_t |
static int |
left_shift
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.left_shift_t |
static int |
LEFTJOIN_OP
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.left_join_t |
static int |
logical_conditions_and
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.logical_and_t |
static int |
logical_conditions_is
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.is_t |
static int |
logical_conditions_not
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.logical_not_t |
static int |
logical_conditions_or
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.logical_or_t |
static int |
logical_conditions_xor
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.logical_xor_t |
static int |
member_of
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.member_of_t |
static int |
MINUS
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.arithmetic_minus_t |
static int |
modelExprOperator
Deprecated.
As of v1.4.3.0
|
static int |
MODULO
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.arithmetic_modulo_t |
static int |
multisetExprOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.multiset_t |
static int |
mysql_binary_operator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_binary_operator_t |
static int |
new_structured_type
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.new_structured_type_t |
static int |
new_variant_type
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.new_variant_type_t |
static int |
nextValueOf
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.next_value_for_t |
static int |
null_conditions
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.null_t |
static int |
objectaccessExprOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.object_access_t |
static int |
pattern_matching_conditions
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.pattern_matching_t |
static int |
period_ldiff
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.period_ldiff_t |
static int |
period_p_intersect
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.period_p_intersect_t |
static int |
period_p_normalize
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.period_p_normalize_t |
static int |
period_rdiff
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.period_rdiff_t |
static int |
placeholderExprOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.place_holder_t |
static int |
PLUS
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.arithmetic_plus_t |
static int |
POWER
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.power_t |
static int |
RANGE
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.range_t |
static int |
ref_arrow
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.ref_arrow_t |
static int |
right_shift
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.right_shift_t |
static int |
RIGHTJOIN_OP
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.right_join_t |
static int |
rowConstructor
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.row_constructor_t |
static int |
SCOPE_RESOLUTION
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.scope_resolution_t |
static int |
simple_comparison_conditions
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.simple_comparison_t |
static int |
simpleConstant
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.simple_constant_t |
static int |
simpleObjectname
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.simple_object_name_t |
static int |
simpleSourcetoken
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.simple_source_token_t |
static int |
sqlserver_proprietary_column_alias
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.sqlserver_proprietary_column_alias_t |
static int |
squareRoot
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_squareroot_t |
static int |
subqueryExprOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.subquery_t |
static int |
TIMES
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.arithmetic_times_t |
static int |
true_false_unknown
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.is_true_t ,
EExpressionType.is_false_t ,EExpressionType.is_unknown_t |
static int |
typecast
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.typecast_t |
static int |
typeconstructorExprOperator
Deprecated.
As of v1.4.3.0
|
static int |
unknown
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.not_initialized_yet_t |
static int |
UnknownOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unknown_t |
static int |
UnknownUnaryOperator
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_left_unknown_t |
static int |
UnknownUnaryOperatorRight
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.unary_right_unknown_t |
static int |
until_changed
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.until_changed_t |
static int |
year_to_month
Deprecated.
As of v1.4.3.0, replaced by
EExpressionType.year_to_month_t |
Constructor and Description |
---|
TExpression() |
TExpression(EExpressionType pExpressionType) |
TExpression(EExpressionType pExpressionType,
TExpression pLeft,
TExpression pRight) |
TExpression(EExpressionType pExpressionType,
TExpression pLeft,
TExpression pRight,
EComparisonType pComparisonType) |
TExpression(TConstant constantOperand) |
TExpression(TFunctionCall functionCall) |
TExpression(TObjectName objectOperand) |
addAllMyTokensToTokenList, appendString, fastSetString, getColumnNo, getDummyTag, getEndToken, getGsqlparser, getLineNo, getNodeType, getStartToken, init, init, removeAllMyTokensFromTokenList, setDummyTag, setEndToken, setEndToken, setEndToken, setEndToken, setGsqlparser, setIncludingComment, setNodeType, setStartToken, setStartToken, setStartToken, setStartToken, setString, toScript, toString
public static final int BigAndOrNestLevel
public static final int unknown
EExpressionType.not_initialized_yet_t
public static final int PLUS
EExpressionType.arithmetic_plus_t
public static final int MINUS
EExpressionType.arithmetic_minus_t
public static final int TIMES
EExpressionType.arithmetic_times_t
public static final int DIVIDE
EExpressionType.arithmetic_divide_t
public static final int CONCATENATE
EExpressionType.concatenate_t
public static final int MODULO
EExpressionType.arithmetic_modulo_t
public static final int ASSIGNMENT
EExpressionType.assignment_t
public static final int BITWISE_AND
EExpressionType.bitwise_and_t
public static final int BITWISE_OR
EExpressionType.bitwise_or_t
public static final int BITWISE_XOR
EExpressionType.bitwise_xor_t
public static final int BITWISE_EXCLUSIVE_OR
EExpressionType.bitwise_exclusive_or_t
public static final int SCOPE_RESOLUTION
EExpressionType.scope_resolution_t
public static final int EXPONENTIATE
EExpressionType.exponentiate_t
public static final int compoundAssignment
EExpressionType.arithmetic_compound_operator_t
public static final int simpleObjectname
EExpressionType.simple_object_name_t
public static final int simpleConstant
EExpressionType.simple_constant_t
public static final int simpleSourcetoken
EExpressionType.simple_source_token_t
public static final int compoundParenthesis
EExpressionType.parenthesis_t
public static final int compoundUnaryPlus
EExpressionType.unary_plus_t
public static final int compoundUnaryMinus
EExpressionType.unary_minus_t
public static final int compoundPrior
EExpressionType.unary_prior_t
public static final int caseExprOperator
EExpressionType.case_t
public static final int cursorExprOperator
EExpressionType.cursor_t
public static final int funcationCallOperator
EExpressionType.function_t
public static final int datetimeExprOperator
public static final int intervalExprOperator
public static final int modelExprOperator
public static final int subqueryExprOperator
EExpressionType.subquery_t
public static final int typeconstructorExprOperator
public static final int objectaccessExprOperator
EExpressionType.object_access_t
public static final int placeholderExprOperator
EExpressionType.place_holder_t
public static final int in_expr
EExpressionType.group_t
public static final int expr_list
EExpressionType.list_t
public static final int dummyOperator
public static final int simple_comparison_conditions
EExpressionType.simple_comparison_t
public static final int group_comparison_conditions
EExpressionType.group_comparison_t
public static final int in_conditions
EExpressionType.in_t
public static final int floating_point_conditions
EExpressionType.floating_point_t
public static final int pattern_matching_conditions
EExpressionType.pattern_matching_t
public static final int null_conditions
EExpressionType.null_t
public static final int between_conditions
EExpressionType.between_t
public static final int exists_condition
EExpressionType.exists_t
public static final int isoftype_condition
EExpressionType.is_of_type_t
public static final int logical_conditions_and
EExpressionType.logical_and_t
public static final int logical_conditions_or
EExpressionType.logical_or_t
public static final int logical_conditions_xor
EExpressionType.logical_xor_t
public static final int logical_conditions_not
EExpressionType.logical_not_t
public static final int logical_conditions_is
EExpressionType.is_t
public static final int RANGE
EExpressionType.range_t
public static final int POWER
EExpressionType.power_t
public static final int at_time_zone
EExpressionType.at_time_zone_t
public static final int at_local
EExpressionType.at_local_t
public static final int day_to_second
EExpressionType.day_to_second_t
public static final int year_to_month
EExpressionType.year_to_month_t
public static final int interval_expression
EExpressionType.interval_t
public static final int new_structured_type
EExpressionType.new_structured_type_t
public static final int new_variant_type
EExpressionType.new_variant_type_t
public static final int period_ldiff
EExpressionType.period_ldiff_t
public static final int period_rdiff
EExpressionType.period_rdiff_t
public static final int period_p_intersect
EExpressionType.period_p_intersect_t
public static final int period_p_normalize
EExpressionType.period_p_normalize_t
public static final int until_changed
EExpressionType.until_changed_t
public static final int is_document
EExpressionType.is_document_t
public static final int is_distinct_from
EExpressionType.is_distinct_from_t
public static final int true_false_unknown
EExpressionType.is_true_t
,
EExpressionType.is_false_t
,EExpressionType.is_unknown_t
public static final int COLLATE
EExpressionType.collate_t
public static final int LEFTJOIN_OP
EExpressionType.left_join_t
public static final int RIGHTJOIN_OP
EExpressionType.right_join_t
public static final int ref_arrow
EExpressionType.ref_arrow_t
public static final int typecast
EExpressionType.typecast_t
public static final int arrayaccess
EExpressionType.arrayaccess_t
public static final int connect_by_root
EExpressionType.unary_connect_by_root_t
public static final int sqlserver_proprietary_column_alias
EExpressionType.sqlserver_proprietary_column_alias_t
public static final int mysql_binary_operator
EExpressionType.unary_binary_operator_t
public static final int left_shift
EExpressionType.left_shift_t
public static final int right_shift
EExpressionType.right_shift_t
public static final int multisetExprOperator
EExpressionType.multiset_t
public static final int fieldSelection
EExpressionType.fieldselection_t
public static final int arrayConstructor
EExpressionType.array_constructor_t
public static final int rowConstructor
EExpressionType.row_constructor_t
public static final int factorial
EExpressionType.unary_factorial_t
public static final int squareRoot
EExpressionType.unary_squareroot_t
public static final int cubeRoot
EExpressionType.unary_cuberoot_t
public static final int factorialPrefix
EExpressionType.unary_factorialprefix_t
public static final int absoluteValue
EExpressionType.unary_absolutevalue_t
public static final int BITWISE_SHIFT_LEFT
EExpressionType.bitwise_shift_left_t
public static final int BITWISE_SHIFT_RIGHT
EExpressionType.bitwise_shift_right_t
public static final int BITWISE_NOT
EExpressionType.unary_bitwise_not_t
public static final int compoundUnaryBitwiseNot
EExpressionType.unary_bitwise_not_t
public static final int member_of
EExpressionType.member_of_t
public static final int nextValueOf
EExpressionType.next_value_for_t
public static final int UnknownOperator
EExpressionType.unknown_t
public static final int UnknownUnaryOperator
EExpressionType.unary_left_unknown_t
public static final int UnknownUnaryOperatorRight
EExpressionType.unary_right_unknown_t
public TExpression()
public TExpression(TObjectName objectOperand)
public TExpression(TConstant constantOperand)
public TExpression(TFunctionCall functionCall)
public TExpression(EExpressionType pExpressionType)
public TExpression(EExpressionType pExpressionType, TExpression pLeft, TExpression pRight)
public TExpression(EExpressionType pExpressionType, TExpression pLeft, TExpression pRight, EComparisonType pComparisonType)
public TCollectionCondition getCollectionCondition()
public TCollectionArray getCollectionArray()
public TNamedParameter getNamedParameter()
public TPositionalParameter getPositionalParameter()
public TArrayConstruct getArrayConstruct()
public TObjectConstruct getObjectConstruct()
public TExpressionList searchColumn(String columnName)
public TSourceToken getAndOrTokenBeforeExpr()
getFlattedAndOrExprs()
public ArrayList getFlattedAndOrExprs()
public void setTokenToIdentifier()
public void setComparisonType(EComparisonType comparisonType)
public static EComparisonType getComparisonType(TSourceToken comparisonOperator)
public TAliasClause getExprAlias()
public void setExprAlias(TAliasClause exprAlias)
public void setDataTypeConversionList(TPTNodeList<TExplicitDataTypeConversion> dataTypeConversionList)
public TPTNodeList<TExplicitDataTypeConversion> getDataTypeConversionList()
public void setDataTypeConversion(TExplicitDataTypeConversion dataTypeConversion)
public TExplicitDataTypeConversion getDataTypeConversion()
getDataTypeConversionList()
public TObjectName getSequenceName()
public TAnalyticFunction getOver_clause()
public THiveVariable getHive_variable()
public void setHive_variable(THiveVariable hive_variable)
public void setSymmetric(boolean symmetric)
public boolean isSymmetric()
public void setObjectAccess(TObjectAccess objectAccess)
public TObjectAccess getObjectAccess()
public boolean isNotOperator()
public void setNotToken(TSourceToken notToken)
public TSourceToken getNotToken()
public void init(Object arg1)
TParseTreeNode
init
in class TParseTreeNode
arg1
- first argumentpublic void setLeadingPrecision(TSourceToken leadingPrecision)
public void setFractionalSecondsPrecision(TSourceToken fractionalSecondsPrecision)
public TSourceToken getLeadingPrecision()
public TSourceToken getFractionalSecondsPrecision()
public void init(Object arg1, Object arg2)
init
in class TParseTreeNode
public void init(Object arg1, Object arg2, Object arg3)
init
in class TParseTreeNode
public void init(Object arg1, Object arg2, Object arg3, Object arg4)
init
in class TParseTreeNode
arg1
- type of this expression, a value of type EExpressionType
arg2
- operator, a value of TSourceToken
arg3
- left operand, a value of TExpression
the meaning of this parameter varies depends on the value of arg1.arg4
- right operand, a value of TExpression
public void setOperatorToken(TSourceToken operatorToken)
public TSourceToken getOperatorToken()
public void setVal(Object val)
public Object getVal()
public TConstant getConstantOperand()
public void setNewVariantTypeArgumentList(TNewVariantTypeArgumentList newVariantTypeArgumentList)
public TNewVariantTypeArgumentList getNewVariantTypeArgumentList()
public void setTypeName(TTypeName typeName)
public TTypeName getTypeName()
public TObjectName getFieldName()
getExpressionType()
is fieldSelection
public void setIndirection(TIndirection indirection)
public boolean isSubscripts()
expression[subscript]
or multiple adjacent elements (an "array slice") can be extracted by writing
expression[lower_subscript:upper_subscript]
In general the array expression must be parenthesized, but the parentheses can be omitted when the expression to be subscripted is just a column reference or positional parameter.
Also, multiple subscripts can be concatenated when the original array is multidimensional. For example:
when sytnax like this:
mytable.arraycolumn[4]
mytable.two_d_column[17][34]
$1[10:42]
check getObjectOperand()
for more detailed information about subscript.
when syntax like this:
(arrayfunction(a,b))[42]
check getIndirection()
when isSubscripts()
is true.
public TIndirection getIndirection()
public boolean isNotModifier()
getNotToken()
public void setOutputFormatPhraseList(TOutputFormatPhraseList outputFormatPhraseList)
public TOutputFormatPhraseList getOutputFormatPhraseList()
column_expr (named alias_name)
public TExpressionList getExprList()
public void setIntervalExpr(TIntervalExpression intervalExpr)
public TIntervalExpression getIntervalExpr()
public void setFieldList(TObjectNameList fieldList)
public TObjectNameList getFieldList()
public void setInExpr(TInExpr inExpr)
public TInExpr getInExpr()
getRightOperand()
public void setExprList(TExpressionList exprList)
public void setOracleOuterJoin(boolean oracleOuterJoin)
public boolean isOracleOuterJoin()
public TExpression getParentExpr()
public void setParentExpr(TExpression parentExpr)
public void setLeftOperand(TExpression leftOperand)
public void setRightOperand(TExpression rightOperand)
public TExpression getRightOperand()
public TExpression getLeftOperand()
public TExpression getLikeEscapeOperand()
public TExpression getBetweenOperand()
public TArrayAccess getArrayAccess()
public EExpressionType getExpressionType()
EExpressionType
public void setExpressionType(EExpressionType exprType)
exprType
- type to distinguish expression, change type from int to
EExpressionType since 1.4.3.0public void setObjectOperand(TObjectName objectOperand)
public TObjectName getObjectOperand()
public void setConstantOperand(TConstant constantOperand)
public TSourceToken getSourcetokenOperand()
public void setSourcetokenOperand(TSourceToken sourcetokenOperand)
public void setCaseExpression(TCaseExpression caseExpression)
public TCaseExpression getCaseExpression()
public void setArrayAccess(TArrayAccess arrayAccess)
public void setSubQueryNode(TSelectSqlNode subQueryNode)
public void setSubQuery(TSelectSqlStatement subQuery)
public TSelectSqlStatement getSubQuery()
public void setSubQueryInStmt(boolean subQueryInStmt)
public TFunctionCall getFunctionCall()
public void setFunctionCall(TFunctionCall functionCall)
public void setDatetimeExpression(TDatetimeExpression datetimeExpression)
public void setIntervalExpression(TIntervalExpression intervalExpression)
public void setBetweenOperand(TExpression betweenOperand)
public void setLikeEscapeOperand(TExpression likeEscapeOperand)
public void doParse(TCustomSqlStatement psql, ESqlClause plocation)
TParseTreeNode
doParse
in class TParseTreeNode
psql
- SQL statement this node belongs toplocation
- SQL clause this node belongs topublic void setQuantifierType(EQuantifierType quantifierType)
public EQuantifierType getQuantifierType()
public EComparisonType getComparisonType()
public TSourceToken getQuantifier()
public TSourceToken getComparisonOperator()
public void setComparisonOperator(TSourceToken comparisonOperator)
public void setQuantifier(TSourceToken quantifier)
public void accept(TParseTreeVisitor v)
TParseTreeNode
accept
in interface Visitable
accept
in class TParseTreeNode
v
- visitor is a descendant class of TParseTreeVisitor
public void acceptChildren(TParseTreeVisitor v)
TParseTreeNode
acceptChildren
in interface Visitable
acceptChildren
in class TParseTreeNode
v
- visitor is a descendant class of TParseTreeVisitor
public boolean isLeaf()
getLeftOperand()
and getRightOperand()
.public boolean isLeafExpr(TParseTreeNode pnode)
public void setVisitSubTree(boolean visitSubTree)
public boolean isVisitSubTree()
public void setWindowSpecification(TWindowDef windowSpecification)
public void preOrderTraverse(IExpressionVisitor ev)
ev
- user defined visitorpublic void inOrderTraverse(IExpressionVisitor ev)
ev
- user defined visitorpublic void postOrderTraverse(IExpressionVisitor ev)
ev
- user defined visitorpublic void addANDCondition(String condition)
condition
- public void addORCondition(String condition)
condition
- public void remove2()
f1 > 1 and f2 > 2, after remove f2>2, parent expression will be changed to: f1 > 1
If we need to remove condition f > 1 from where clause: where f > 1, Here f > 1 is the top level expression, after remove it from where clause, only WHERE keyword left in where clause.
public void remove()
public void copyTo(TExpression target)
public static TExpression mergeObjectNameList(TExpression expr, TObjectNameList objectNameList)
Copyright © 2019. All rights reserved.