Package org.h2.command.dml

# Class CommandWithValues

java.lang.Object
org.h2.command.Prepared
org.h2.command.dml.DataChangeStatement
org.h2.command.dml.CommandWithValues

Direct Known Subclasses:
  `Insert`, `Merge`

public abstract class CommandWithValues extends DataChangeStatement
Command that supports VALUES clause.

## Field Summary

Fields
Modifier and Type
Field
Description
`protected final ArrayList<Expression[]>`
`valuesExpressionList`
Expression data for the VALUES clause.

### Fields inherited from class org.h2.command.Prepared

`create, parameters, prepareAlways, session, sqlStatement, sqlTokens`

## Constructor Summary

Constructors
Modifier
Constructor
Description
`protected`
`CommandWithValues(SessionLocal session)`
Creates new instance of command with VALUES clause.

## Method Summary

Modifier and Type
Method
Description
`void`
`addRow(Expression[] expr)`
Add a row to this command.

### Methods inherited from class org.h2.command.dml.DataChangeStatement

`getStatementName, getTable, isCacheable, isTransactional, lockAndRecheckCondition, prepare, queryMeta, update, update`

### Methods inherited from class org.h2.command.Prepared

`checkCanceled, checkParameters, collectDependencies, getCurrentRowNumber, getDatabase, getObjectId, getParameters, getPersistedObjectId, getPlanSQL, getPlanSQL, getSession, getSimpleSQL, getSQL, getSQLTokens, getType, invalidateCachedResult, isQuery, isReadOnly, isRetryable, isWithParamValues, needRecompile, query, setCommand, setCurrentRowNumber, setParameterList, setPersistedObjectId, setPrepareAlways, setRow, setSession, setSQL, setWithParamValues, toString`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Field Details

### valuesExpressionList

protected final ArrayList<Expression[]> valuesExpressionList
Expression data for the VALUES clause.

## Constructor Details

### CommandWithValues

protected CommandWithValues(SessionLocal session)
Creates new instance of command with VALUES clause.

Parameters:
  `session` - the session

## Method Details

### addRow

public void addRow(Expression[] expr)
Add a row to this command.

Parameters:
  `expr` - the list of values