Top Description Fields Constructors Methods
org.h2.command.dml

public Class RunScriptCommand

extends ScriptBase
Class Inheritance
Imports
java.io.IOException, java.nio.charset.Charset, .StandardCharsets, org.h2.command.CommandContainer, .CommandInterface, .Prepared, org.h2.engine.SessionLocal, org.h2.message.DbException, org.h2.result.ResultInterface, org.h2.util.ScriptReader, .StringUtils

This class represents the statement RUNSCRIPT

Field Summary

Modifier and TypeField and Description
private Charset
private boolean
private boolean
private static final char
UTF8_BOM

The byte order mark.

private boolean
Inherited from org.h2.command.dml.ScriptBase:
outreader

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private void
public int
getType()

Implements abstract org.h2.command.Prepared.getType.

Get the command type as defined in CommandInterface

public ResultInterface
queryMeta()

Implements abstract org.h2.command.Prepared.queryMeta.

Get an empty result set containing the meta data.

public void
public void
setFrom1X()

Enables quirks for parsing scripts from H2 1.*.*.

public void
setQuirksMode(boolean
whether quirks mode should be enabled
quirksMode
)

Enables or disables the quirks mode.

public void
setVariableBinary(boolean
true to parse BINARY as VARBINARY, false to parse it as is
variableBinary
)

Changes parsing of a BINARY data type.

public long
update()

Overrides org.h2.command.Prepared.update.

Execute the statement.

Inherited from org.h2.command.dml.ScriptBase:
closeIOdeleteStoregetFileNameisTransactionalneedRecompileopenInputopenOutputsetCiphersetCompressionAlgorithmsetFileNameExprsetPassword

Field Detail

charsetback to summary
private Charset charset
from1Xback to summary
private boolean from1X
quirksModeback to summary
private boolean quirksMode
UTF8_BOMback to summary
private static final char UTF8_BOM

The byte order mark. 0xfeff because this is the Unicode char represented by the UTF-8 byte order mark (EF BB BF).

variableBinaryback to summary
private boolean variableBinary

Constructor Detail

RunScriptCommandback to summary
public RunScriptCommand(SessionLocal session)

Method Detail

executeback to summary
private void execute(String sql)
getTypeback to summary
public int getType()

Implements abstract org.h2.command.Prepared.getType.

Doc from org.h2.command.Prepared.getType.

Get the command type as defined in CommandInterface

Returns:int

the statement type

Annotations
@Override
queryMetaback to summary
public ResultInterface queryMeta()

Implements abstract org.h2.command.Prepared.queryMeta.

Doc from org.h2.command.Prepared.queryMeta.

Get an empty result set containing the meta data.

Returns:ResultInterface

the result set

Annotations
@Override
setCharsetback to summary
public void setCharset(Charset charset)
setFrom1Xback to summary
public void setFrom1X()

Enables quirks for parsing scripts from H2 1.*.*.

setQuirksModeback to summary
public void setQuirksMode(boolean quirksMode)

Enables or disables the quirks mode.

Parameters
quirksMode:boolean

whether quirks mode should be enabled

setVariableBinaryback to summary
public void setVariableBinary(boolean variableBinary)

Changes parsing of a BINARY data type.

Parameters
variableBinary:boolean

true to parse BINARY as VARBINARY, false to parse it as is

updateback to summary
public long update()

Overrides org.h2.command.Prepared.update.

Doc from org.h2.command.Prepared.update.

Execute the statement.

Returns:long

the update count

Annotations
@Override