站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss 3.2.7 server API Documentation 英文版文档

JDBCOracleSequenceCreateCommand (JBoss Server API) - JBoss 3.2.7 server API Documentation 英文版文档


org.jboss.ejb.plugins.cmp.jdbc.keygen
Class JDBCOracleSequenceCreateCommand

java.lang.Object
  extended byorg.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand
      extended byorg.jboss.ejb.plugins.cmp.jdbc.JDBCIdentityColumnCreateCommand
          extended byorg.jboss.ejb.plugins.cmp.jdbc.keygen.JDBCOracleSequenceCreateCommand
All Implemented Interfaces:
JDBCCreateCommand

public class JDBCOracleSequenceCreateCommand
extends JDBCIdentityColumnCreateCommand

Create command for use with Oracle that uses a sequence in conjuction with a RETURNING clause to generate keys in a single statement The sequence is called by the parameter attribute "sequence_name". As an example, the sequence_name could be %%t_sequence to use _sequence for each distinct table.

Version:
$Revision: 1.1 $
Author:
Guillaume Compagnon

Field Summary
 
Fields inherited from class org.jboss.ejb.plugins.cmp.jdbc.JDBCIdentityColumnCreateCommand
pkField, pkSQL
 
Fields inherited from class org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand
createAllowed, debug, entity, exceptionProcessor, insertAfterEjbPostCreate, insertFields, insertSQL, log, securityManager, trace
 
Constructor Summary
JDBCOracleSequenceCreateCommand()
           
 
Method Summary
protected  int executeInsert(PreparedStatement ps, EntityEnterpriseContext ctx)
           
 void init(JDBCStoreManager manager)
           
protected  void initEntityCommand(JDBCEntityCommandMetaData entityCommand)
           
protected  void initInsertSQL()
           
protected  PreparedStatement prepareStatement(Connection c, String sql, EntityEnterpriseContext ctx)
           
 
Methods inherited from class org.jboss.ejb.plugins.cmp.jdbc.JDBCIdentityColumnCreateCommand
executeInsert, initGeneratedFields, isInsertField, processException
 
Methods inherited from class org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand
afterInsert, beforeInsert, checkCreateAllowed, execute, generateFields, getGeneratedPKField, getPrimaryKey, initInsertFields, performInsert
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JDBCOracleSequenceCreateCommand

public JDBCOracleSequenceCreateCommand()
Method Detail

init

public void init(JDBCStoreManager manager)
          throws org.jboss.deployment.DeploymentException
Specified by:
init in interface JDBCCreateCommand
Overrides:
init in class JDBCAbstractCreateCommand
Throws:
org.jboss.deployment.DeploymentException

initEntityCommand

protected void initEntityCommand(JDBCEntityCommandMetaData entityCommand)
                          throws org.jboss.deployment.DeploymentException
Overrides:
initEntityCommand in class JDBCAbstractCreateCommand
Throws:
org.jboss.deployment.DeploymentException

initInsertSQL

protected void initInsertSQL()
Overrides:
initInsertSQL in class JDBCAbstractCreateCommand

prepareStatement

protected PreparedStatement prepareStatement(Connection c,
                                             String sql,
                                             EntityEnterpriseContext ctx)
                                      throws SQLException
Overrides:
prepareStatement in class JDBCAbstractCreateCommand
Throws:
SQLException

executeInsert

protected int executeInsert(PreparedStatement ps,
                            EntityEnterpriseContext ctx)
                     throws SQLException
Throws:
SQLException


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.