Class TMergeSqlStatement

All Implemented Interfaces:
IRelation, Visitable, Iterator<TSourceToken>

Merge SQL statement.

TCustomSqlStatement.getTargetTable() returns the target table.
getUsingTable() returns the source table in the using clause.
getCondition() returns the merge search condition.
getWhenClauses() returns when MATCHED/NOT MATCHED clauses.
     merge into target_table [column_list]
     using source_table|subquery
     on merge_search_condition
     [when matched [and search_conditions ] then update set {col_name = expression} | delete]
     [when not matched [and search_conditions ] then insert [(column_list)] values (value_list)]
  

call TCustomSqlStatement.getTargetTable() to return a value for target_table.

column_list can be fetched from getColumnList() if any.

source_table in using clause can be fetched via getUsingTable(), subquery treated as a table as well.

call getCondition() to return merge_search_condition.

when [not] matched clause is available by calling getWhenClauses() which is a list of type TMergeWhenClause.

See Also: