Top Description Fields Constructors Methods
org.eclipse.persistence.queries

public Class DataModifyQuery

extends ModifyQuery
Class Inheritance
Imports
org.eclipse.persistence.exceptions.*, org.eclipse.persistence.internal.sessions.UnitOfWorkImpl

Purpose: Concrete class used for executing non selecting SQL strings.

Responsibilities:

Author
Yvon Lavoie
Since
TOPLink/Java 1.0

Field Summary

Modifier and TypeField and Description
protected boolean
hasModifyRow

Used to distinguish query that have a different modify row than translation row.

Inherited from org.eclipse.persistence.queries.ModifyQuery:
forceBatchStatementExecutionisBatchExecutionSupportedmodifyRow

Constructor Summary

AccessConstructor and Description
public
public
DataModifyQuery(String sqlString)

Warning

Allowing an unverified SQL string to be passed into this method makes your application vulnerable to SQL injection attacks.

public

Method Summary

Modifier and TypeMethod and Description
public Object
executeDatabaseQuery()

Implements abstract org.eclipse.persistence.queries.DatabaseQuery.executeDatabaseQuery.

INTERNAL: Perform the work to execute the SQL call.
public boolean
hasModifyRow()

Return if a modify row has been set.

public boolean
isDataModifyQuery()

Overrides org.eclipse.persistence.queries.DatabaseQuery.isDataModifyQuery.

PUBLIC: Return if this is a data modify query.
protected void
prepare()

Overrides org.eclipse.persistence.queries.DatabaseQuery.prepare.

INTERNAL: Prepare the receiver for execution in a session.
public void
prepareForExecution()

Overrides org.eclipse.persistence.queries.DatabaseQuery.prepareForExecution.

INTERNAL: Prepare the receiver for execution in a session.
public void
setHasModifyRow(boolean hasModifyRow)

Set if a modify row has been set.

Inherited from org.eclipse.persistence.queries.ModifyQuery:
forceBatchStatementExecutiongetModifyRowisBatchExecutionSupportedisModifyQuerysetForceBatchStatementExecutionsetIsBatchExecutionSupportedsetModifyRow

Field Detail

hasModifyRowback to summary
protected boolean hasModifyRow

Used to distinguish query that have a different modify row than translation row.

Constructor Detail

DataModifyQueryback to summary
public DataModifyQuery()
DataModifyQueryback to summary
public DataModifyQuery(String sqlString)

Warning

Allowing an unverified SQL string to be passed into this method makes your application vulnerable to SQL injection attacks.

DataModifyQueryback to summary
public DataModifyQuery(Call call)

Method Detail

executeDatabaseQueryback to summary
public Object executeDatabaseQuery() throws DatabaseException

Implements abstract org.eclipse.persistence.queries.DatabaseQuery.executeDatabaseQuery.

INTERNAL: Perform the work to execute the SQL call. Return the row count of the number of rows effected by the SQL call.

Returns:Object

Doc from org.eclipse.persistence.queries.DatabaseQuery.executeDatabaseQuery.

- the result of executing the query.

Annotations
@Override
Exceptions
DatabaseException:

Doc from org.eclipse.persistence.queries.DatabaseQuery.executeDatabaseQuery.

- an error has occurred on the database.

hasModifyRowback to summary
public boolean hasModifyRow()

Return if a modify row has been set. Allows distinguishing query that have a different modify row than translation row.

isDataModifyQueryback to summary
public boolean isDataModifyQuery()

Overrides org.eclipse.persistence.queries.DatabaseQuery.isDataModifyQuery.

PUBLIC: Return if this is a data modify query.

Annotations
@Override
prepareback to summary
protected void prepare()

Overrides org.eclipse.persistence.queries.DatabaseQuery.prepare.

INTERNAL: Prepare the receiver for execution in a session.

Annotations
@Override
prepareForExecutionback to summary
public void prepareForExecution() throws QueryException

Overrides org.eclipse.persistence.queries.DatabaseQuery.prepareForExecution.

INTERNAL: Prepare the receiver for execution in a session. In particular, set the descriptor of the receiver to the ClassDescriptor for the appropriate class for the receiver's object.

Annotations
@Override
setHasModifyRowback to summary
public void setHasModifyRow(boolean hasModifyRow)

Set if a modify row has been set. Allows distinguishing query that have a different modify row than translation row.