flux.database
Interface DatabaseInsertAction
- All Superinterfaces:
- Action, java.lang.Cloneable, DatabaseAction, RuntimeDataMap, java.io.Serializable
- public interface DatabaseInsertAction
- extends DatabaseAction
Adds or updates a single row, or multiple rows, in a database. The database
connection available to the flow context can be used, or alternatively, database
connection information can be provided to connect to a data source or direct JDBC
connection.
A minimum of one SQL statement must be provided, the insert statement. Optional
query and update statements can be provided to instruct this action to update
existing rows in the database, rather than inserting new rows.
- Author:
- Copyright 2000-2008 Flux Corporation. All rights reserved.
|
Method Summary |
java.lang.String |
getInsertStatement()
Returns the database statement that is used to insert rows into
the database. |
java.lang.String |
getQueryStatement()
Returns the database statement that is used to determine whether this action
should execute the insert or update SQL statement. |
java.lang.String |
getUpdateStatement()
Returns the database statement that is used to update rows in the database
when the query statement returns one or more rows. |
void |
setInsertStatement(java.lang.String statement)
Returns the database statement that is used to insert rows in the database
when the query statement does not return any rows. |
void |
setQueryStatement(java.lang.String statement)
Returns the database statement that is used to determine whether to execute
the insert or update statement. |
void |
setUpdateStatement(java.lang.String statement)
Sets the database query that is used to detect business exceptions in the
database. |
| Methods inherited from interface flux.database.DatabaseAction |
getBuiltinDatabaseConnection, getDataSource, getDataSourceInitialContextFactory, getDataSourceInitialContextPassword, getDataSourceInitialContextProviderUrl, getDataSourceInitialContextUsername, getDataSourcePassword, getDataSourceUsername, getJdbcDriver, getJdbcPassword, getJdbcUrl, getJdbcUsername, setBuiltinDatabaseConnection, setDataSource, setDataSourceInitialContextFactory, setDataSourceInitialContextPassword, setDataSourceInitialContextProviderUrl, setDataSourceInitialContextUsername, setDataSourcePassword, setDataSourceUsername, setJdbcDriver, setJdbcPassword, setJdbcUrl, setJdbcUsername |
| Methods inherited from interface flux.Action |
addFlow, addFlow, addSignalFlow, clone, getFlows, getHiddenVariableNames, getJoinExpression, getName, getPostscript, getPostscriptLanguage, getPrescript, getPrescriptLanguage, getResultInfo, getSignalsToMonitor, getTimeoutBusinessInterval, getTimeoutExpression, getVariableManager, isEndOfRun, isJoinPoint, isSkippable, isStartAction, isStartOfRun, isTransactionBreak, removeFlow, reset, setElseFlow, setEndOfRun, setErrorFlow, setErrorFlowWithoutRollback, setErrorFlowWithRollback, setJoinExpression, setJoinPoint, setName, setPostscript, setPostscriptLanguage, setPrescript, setPrescriptLanguage, setSignalsToMonitor, setSkippable, setStartAction, setStartOfRun, setTimeoutBusinessInterval, setTimeoutExpression, setTimeoutFlow, setTransactionBreak, verify, verifyOnClient |
getInsertStatement
public java.lang.String getInsertStatement()
- Returns the database statement that is used to insert rows into
the database.
- Returns:
- The database statement that is used to insert rows into
the database.
getQueryStatement
public java.lang.String getQueryStatement()
- Returns the database statement that is used to determine whether this action
should execute the insert or update SQL statement. The insert statement will
be executed if a query statement is specified and the query statement retuns
one or more rows.
- Returns:
- The database statement that is used to determine whether this action
should execute the insert or update SQL statement.
getUpdateStatement
public java.lang.String getUpdateStatement()
- Returns the database statement that is used to update rows in the database
when the query statement returns one or more rows.
- Returns:
- The database statement that is used to update rows in the database.
setInsertStatement
public void setInsertStatement(java.lang.String statement)
- Returns the database statement that is used to insert rows in the database
when the query statement does not return any rows.
- Parameters:
statement - The database statement that is used to insert rows in the database.
setQueryStatement
public void setQueryStatement(java.lang.String statement)
- Returns the database statement that is used to determine whether to execute
the insert or update statement. The insert update is executed when this
query statement does not return any rows. The update statement is executed
if this query statement returns one or more rows.
- Parameters:
statement - The database statement that is used to determine whether to execute the insert or update statement.
setUpdateStatement
public void setUpdateStatement(java.lang.String statement)
- Sets the database query that is used to detect business exceptions in the
database. The exception condition is tested using the results of this
database query in order to detect business exceptions.
- Parameters:
statement - The database query that is used to detect business exceptions
in the database.
© 2000-2008 Flux Corporation. All rights reserved.