Ver Mensaje Individual
  #2 (permalink)  
Antiguo 22/10/2009, 09:31
manpazm
 
Fecha de Ingreso: octubre-2009
Mensajes: 1
Antigüedad: 14 años, 6 meses
Puntos: 0
Respuesta: Java Cómo hacer 1 Execute Immediate?

Estimado AXZ,

Debes ejecutar la sentencia ORACLE sin EXECUTE IMMEDIATE:

Connection connection = null;
try
{
InitialContext initialContext = new InitialContext();
DataSource dataSource = null;
dataSource = ( DataSource )initialContext.lookup( "jdbc/conPUCoreDS" );
connection = dataSource.getConnection();

PreparedStatement pStmt = connection.prepareStatement( " 'ALTER SESSION SET NLS_LANGUAGE = AMERICAN';" );
pStmt.execute();
pStmt.close();
...