Class SQLInsertStatement
- java.lang.Object
-
- com.alibaba.druid.sql.ast.SQLObjectImpl
-
- com.alibaba.druid.sql.ast.SQLStatementImpl
-
- com.alibaba.druid.sql.ast.statement.SQLInsertInto
-
- com.alibaba.druid.sql.ast.statement.SQLInsertStatement
-
- All Implemented Interfaces:
SQLDbTypedObject,SQLObject,SQLReplaceable,SQLStatement
- Direct Known Subclasses:
HiveInsertStatement,MySqlInsertStatement,OracleInsertStatement,OscarInsertStatement,PGInsertStatement,SQLServerInsertStatement
public class SQLInsertStatement extends SQLInsertInto implements SQLStatement
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSQLInsertStatement.ValuesClause
-
Field Summary
Fields Modifier and Type Field Description protected booleanupsertprotected SQLWithSubqueryClausewith-
Fields inherited from class com.alibaba.druid.sql.ast.statement.SQLInsertInto
columns, columnsString, columnsStringHash, insertBeforeComments, overwrite, partitions, query, tableSource, valuesList
-
Fields inherited from class com.alibaba.druid.sql.ast.SQLStatementImpl
afterSemi, dbType, headHints
-
Fields inherited from class com.alibaba.druid.sql.ast.SQLObjectImpl
attributes, hint, parent, sourceColumn, sourceLine
-
-
Constructor Summary
Constructors Constructor Description SQLInsertStatement()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaccept0(SQLASTVisitor visitor)SQLInsertStatementclone()voidcloneTo(SQLInsertStatement x)List<SQLObject>getChildren()DbTypegetDbType()SQLWithSubqueryClausegetWith()booleanisAfterSemi()booleanisUpsert()voidsetAfterSemi(boolean afterSemi)voidsetDbType(DbType dbType)voidsetUpsert(boolean upsert)voidsetWith(SQLWithSubqueryClause with)StringtoString()-
Methods inherited from class com.alibaba.druid.sql.ast.statement.SQLInsertInto
addColumn, addInsertBeforeComment, addPartition, addValueCause, cloneTo, getAlias, getColumns, getColumnsString, getColumnsStringHash, getHint, getInsertBeforeCommentsDirect, getPartitions, getQuery, getTableName, getTableSource, getValues, getValuesList, isOverwrite, replace, setAlias, setColumnsString, setHint, setOverwrite, setQuery, setQuery, setTableName, setTableSource, setTableSource, setValues
-
Methods inherited from class com.alibaba.druid.sql.ast.SQLStatementImpl
cloneTo, getHeadHintsDirect, setHeadHints, toLowerCaseString, toParameterizedString, toString, toUnformattedString
-
Methods inherited from class com.alibaba.druid.sql.ast.SQLObjectImpl
accept, acceptChild, acceptChild, addAfterComment, addAfterComment, addBeforeComment, addBeforeComment, cloneTo, computeDataType, containsAttribute, getAfterCommentsDirect, getAttribute, getAttributes, getAttributesDirect, getBeforeCommentsDirect, getParent, getParent, getSourceColumn, getSourceLine, hasAfterComment, hasBeforeComment, output, putAttribute, setParent, setSource, setSourceLine
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.alibaba.druid.sql.ast.SQLObject
accept, addAfterComment, addAfterComment, addBeforeComment, addBeforeComment, containsAttribute, getAfterCommentsDirect, getAttribute, getAttributes, getAttributesDirect, getBeforeCommentsDirect, getParent, getParent, getSourceColumn, getSourceLine, hasAfterComment, hasBeforeComment, output, putAttribute, setParent, setSource
-
Methods inherited from interface com.alibaba.druid.sql.ast.SQLStatement
getHeadHintsDirect, setHeadHints, toLowerCaseString, toParameterizedString, toString
-
-
-
-
Field Detail
-
with
protected SQLWithSubqueryClause with
-
upsert
protected boolean upsert
-
-
Method Detail
-
cloneTo
public void cloneTo(SQLInsertStatement x)
-
clone
public SQLInsertStatement clone()
- Specified by:
clonein interfaceSQLObject- Specified by:
clonein interfaceSQLStatement- Specified by:
clonein classSQLInsertInto
-
accept0
protected void accept0(SQLASTVisitor visitor)
- Overrides:
accept0in classSQLStatementImpl
-
getChildren
public List<SQLObject> getChildren()
- Specified by:
getChildrenin interfaceSQLStatement- Overrides:
getChildrenin classSQLStatementImpl
-
isUpsert
public boolean isUpsert()
-
setUpsert
public void setUpsert(boolean upsert)
-
getDbType
public DbType getDbType()
- Specified by:
getDbTypein interfaceSQLDbTypedObject- Specified by:
getDbTypein interfaceSQLStatement- Overrides:
getDbTypein classSQLStatementImpl
-
setDbType
public void setDbType(DbType dbType)
- Overrides:
setDbTypein classSQLStatementImpl
-
isAfterSemi
public boolean isAfterSemi()
- Specified by:
isAfterSemiin interfaceSQLStatement- Overrides:
isAfterSemiin classSQLStatementImpl
-
setAfterSemi
public void setAfterSemi(boolean afterSemi)
- Specified by:
setAfterSemiin interfaceSQLStatement- Overrides:
setAfterSemiin classSQLStatementImpl
-
getWith
public SQLWithSubqueryClause getWith()
-
setWith
public void setWith(SQLWithSubqueryClause with)
-
toString
public String toString()
- Specified by:
toStringin interfaceSQLStatement- Overrides:
toStringin classSQLStatementImpl
-
-