Oracle 9i JDBC configuration failure?

I am testing some Java servlet (run over tomcat container) which needs to access the Oracle DB installed on the same Solaris server.
It works well with Oracle 8i, and we then install the program on another Oracle 9i server.
when we set up the DB and use SQL *Plus to access the DB it works-- and when running netstat on Solaris-- the port 1521 is not open-- that is the default port for JDBC, and it should be open.
My java program shows the following error
java.sql.SQLException
: Io exception: The Network Adapter could not establish the connection
As port 1521 is not open at all so the servlet running on the same machine can't access it.
Could you kindly help give advice --- on 9i, how shall I check the setting to make sure JDBC is well configured and ready for use? A thousand thanks

Hi Li,
You don't have to do a netstat to check for the port. Use the lsnrctl utility. Its found in ORACLE_HOME/bin directory.
Listener is the program which recieves all the requests to database and sends it to Oracle for processing, and returns the results back.
$lsnrctl status
-- this will show if the Listener is running or not
$lsnrctl start
-- this will start the listener in the port specified in ORACLE_HOME/network/admin/listener.ora
$lsnrctl stop
-- stop the listener
If your listener is not running, start the listener and try connecting.
If your listener is not running, then you cann't connect even using sqlplus.
Elango.

Similar Messages

  • Oracle keeping JDBC connections ...

    All
    has anyone come got any ideas on this:
    WLS6.0 sp2 on Win2k
    Oracle v8
    JDBC connection pool configured with 10 min connections / 50 max conns (in
    increments of 5). Shrinking is active, and is set to run every 15mins.
    What were seeing is that Oracle doesnt let go of any of the JDBC
    connections. It literally keeps them for days on end, until we have to
    manually kill them because theyre causing other DB problems.
    any ideas ?
    tks
    will

    Hello, I am using ALUI G6 (former Plumtree) and I am experiencing the same problem.
    JDBC connections are not released and we reach the connection max number easily.
    Please, can somebody help us ?
    Thanks for your help,
    Kind regards

  • JCA / JDBC Configured for non-XA Attempting XA Transaction Commit

    I am attempting to create simple BPEL SOA composites in SOA 11.1.1.5 that use a DbAdapter to execute a stored procedure in an 11g database. The database task being performed only involves a single database and does not require transaction support. I have carefully stepped through the creation of the DataSource and JCA pointing through the DbAdapter to the JDBC DataSource so XA transaction support is disabled, the JCA pool sets the transaction mode to "No transaction" and the JCA pool uses the dataSource value to point to the JNDI name of the JDBC pool rather than the xADataSource value.
    Visually,
    DataSource definition:
    name = jdbc/myserviceDataSource
    driver = oracle.jdbc.xa.client.OracleXADataSource
    url = jdbc:oracle:thin:@mydbhost.myfirm.com:1521:GENERIC
    use XA DataSource = unchecked
    set XA timeout = unchecked
    Keep XA connection until transaction complete = checked
    keep connection after local transaction = checked
    JCA definition:
    name = eis/DB/myserviceDataSource
    dataSourceName = jdbc/myserviceDataSource
    xADataSourceName = (blank)
    platform class name = org.eclipse.persistence.platform.database.Oracle10Platform
    Transaction | Transaction Support: no transaction
    This configuration works on one sandbox server and I got it working in a second sandbox server. However, after deleting the JDBC and JCA pools to go through the process one more time to document the procedure on the second server, I am unable to get the configuration working again. The WebLogic domain appears to be resurrecting portions of an old configuration that still references the JNDI name of the JDBC pool in the xADataSourceName parameter. I have unpacked the DbAdapter.rar archive for the DbAdapter and verified the contents of the ./META-INF/weblogic-ra.xml file don't use the xADataSouceName parameter. The Deployment Plan for the DbAdapter (named DbAdapterPlan.xml in $SOA_HOME/soa/connectors ) also explicitly configures the JCA pool using the dataSourceName value leaving the xADataSourceName value blank.
    However, executing the SOA service using this JCA connection results in this error:
    java.sql.SQLException: Cannot call Connection.commit in distributed transaction.
    Again, I know the theoretical answer to this question is to disable transactions in the JCA and JDBC configurations and don't use the xADataSourceName element of the JCA configuration to point to the JDBC pool. However, after validating those elements and restarting the pools or performing an Update on the DbAdapter deployment, WebLogic seems to still create connections through the JDBC pool with transactions enabled.
    Any suggestions?
    Should I just completely undeploy the DbAdapter and redeploy it from the SOA binary installation directory? These are just lab machines right now so that's obviously not a good long term answer for production use but may help start over with refining a better procedure for doing this.

    You should use a non-xa driver for your data source...
    From the weblogic docs...
    Configure Transaction Options
    When you configure a JDBC data source using the Administration Console, WebLogic Server automatically selects specific transaction options based on the type of JDBC driver:
    For XA drivers, the system automatically selects the Two-Phase Commit protocol for global transaction processing.
    For non-XA drivers, local transactions are supported by definition, and WebLogic Server offers the following options ...
    http://docs.oracle.com/cd/E23943_01/web.1111/e13737/jdbc_datasources.htm#autoId8
    Cheers,
    Vlad

  • "Oracle Audit Vault Configuration Assistant" failed

    Hello everyone, I can across this issue while installing AV agent and wanted to know if any one can help with a quick solution. OS= Linux 5, agent_software= 10.2.3 and here is the error messages:
    ++**INFO: Configuration assistant "Oracle Audit Vault Agent One-Off Patches" succeeded**++
    ++**INFO: Command = oracle.av.common.AvcaCfgPlugIn /app/oracle/product/10.2.0/agent_home/bin/avca -s initialize_agent -agentname agentdevmdb1 -agentusr ${s_agentusr} -agentport 7016 -av AHS-SOASOV1-DEVM.ahs.state.vt.us:1521:av.ahs.state.vt.us -rmiport 3121 -jmsport 3300**++
    ++**Command = oracle.av.common.AvcaCfgPlugIn has failed**++
    ++**INFO: Configuration assistant "Oracle Audit Vault Configuration Assistant" failed**++
    ++**-----------------------------------------------------------------------------**++
    ++***** Starting OUICA *****++
    ++**Oracle Home set to /app/oracle/product/10.2.0/agent_home**++
    ++**Configuration directory is set to /app/oracle/product/10.2.0/agent_home/cfgtoollogs. All xml files under the directory will be processed**++
    ++**INFO: The "/app/oracle/product/10.2.0/agent_home/cfgtoollogs/configToolFailedCommands" script contains all commands that failed, were skipped or were cancelled. This file may be used to run these configuration assistants outside of OUI. Note that you may have to update this script with passwords (if any) before executing the same.**++
    ++**-----------------------------------------------------------------------------**++
    ++**INFO: Created a new file /app/oracle/product/10.2.0/agent_home/cfgtoollogs/configToolFailedCommands**++
    ++**INFO: Since the option is to overwrite the existing /app/oracle/product/10.2.0/agent_home/cfgtoollogs/configToolFailedCommands file, backing it up**++
    ++**INFO: The backed up file name is /app/oracle/product/10.2.0/agent_home/cfgtoollogs/configToolFailedCommands.bak**++
    ++**SEVERE: OUI-25031:Some of the configuration assistants failed. It is strongly recommended that you retry the configuration assistants at this time. Not successfully running any "Recommended" assistants means your system will not be correctly configured.**++
    ++**1. Check the Details panel on the Configuration Assistant Screen to see the errors resulting in the failures.**++
    ++**2. Fix the errors causing these failures.**++
    ++**3. Select the failed assistants and click the 'Retry' button to retry them.**++
    ++**INFO: User Selected: Yes/OK**++

    Hi:
    A log of everything the avca command is trying to do is kept in $ORACLE_HOME/av/log/avca.log. Please review that to see what could have caused the issue.

  • Configuration assistant "Oracle Notification Server Configuration Assistan

    Facing below issue on setup of RAC in vmware
    Note: Do not run the scripts simultaneously on the listed nodes.
    INFO: Starting to execute configuration assistants
    INFO: Command = /u01/crs/oracle/product/10.2.0/crs/bin/racgons add_config rac1.localhost:6200 rac2.localhost:6200
    Command = /u01/crs/oracle/product/10.2.0/crs/bin/racgons has failed
    INFO: Configuration assistant "Oracle Notification Server Configuration Assistant" failed
    *** Starting OUICA ***
    Oracle Home set to /u01/crs/oracle/product/10.2.0/crs
    Configuration directory is set to /u01/crs/oracle/product/10.2.0/crs/cfgtoollogs. All xml files under the directory will be processed
    INFO: The "/u01/crs/oracle/product/10.2.0/crs/cfgtoollogs/configToolFailedCommands" script contains all commands that failed, were skipped or were cancelled. This file may be used to run these configuration assistants outside of OUI. Note that you may have to update this script with passwords (if any) before executing the same.
    SEVERE: OUI-25031:Some of the configuration assistants failed. It is strongly recommended that you retry the configuration assistants at this time. Not successfully running any "Recommended" assistants means your system will not be correctly configured.
    1. Check the Details panel on the Configuration Assistant Screen to see the errors resulting in the failures.
    2. Fix the errors causing these failures.
    3. Select the failed assistants and click the 'Retry' button to retry them.
    INFO: User Selected: Yes/OK
    any workaround pls
    Regards,
    Amin Anwar
    Edited by: A. Anwar on Oct 17, 2012 2:24 AM

    Hi,
    best would be to take the actual version of Oracle (11gR2), which fixes a lot of bugs (also in installation), than to analyze problems based on old versions.
    Even if you need older databases (10.2, which I don't hope since support is ending soon), you should at least think about taking the newest version for Oracle Clusterware (Grid infrastructure), .
    Regards
    Sebastian

  • Getting started with oracle and jdbc

    i have downloaded ojdbc14.zip from oracle.com
    it's documentation only tells you about the api and the packages and nothing about how to configure it.
    how do i get started? where do i unzip those files and what to do next?
    please help

    "The Old oracle.jdbc.driver Package Will Go Away Soon
    If you still have existing applications that use the
    old oracle.jdbc.driver
    package, now is the time to convert your code."
    And who is so foolish as to use concrete types
    instead of java.sql and javax.sql interfaces or embed
    driver class names in their code? Well, anybody who's more interested in optimal performance than being generic, and willing to put up with the headaches of that, such as providers of high-performance OR mapping tools or someone tuning a very heavily used bit. Or anybody working in a committed Oracle-only shop. It's not a one-size-fits-all world...
    Again, Oracle is evolving the standard. No, the standard is Sun's java.sql interface.Yea, Sun evolved Java, and Oracle is recommending the use of Datasources to keep step with that evolution...
    This still
    works, but Oracle is shifting away from <sid> and
    using <service name> instead. The alternate syntax
    for the URL is:
    String url=jdbc:oracle:thin:@<host>:<port>/<database>
    This has been true for as long as Oracle has had a
    thin, type IV JDBC driver. The URL syntax hasn't
    changed.
    Yes it has and Oracle says it has, here:
    http://download-west.oracle.com/docs/cd/B14117_01/java.101/b10979/urls.htm#BEIJFHHB
    Wherein it is written, in Section 3.2.1 of the Oracle� Database JDBC Developer's Guide and Reference, the sesction on the several supported URL formats for Oracle 10.1
    Notes:
    * Oracle Service IDs are no longer supported at 10g Release 1 (10.1).
    They go on to list three URL styles supported:
    Oracle Net connection descriptor - like an entry in tnsnames.ora (ick!)
    Thin-style service name - the most common, what was quoted above.
    LDAP syntax - for having an LDAP service resolve the database for you
    However, in the old 8.1.7 JDBC documentation, here:
    http://download-east.oracle.com/docs/cd/A87860_01/doc/java.817/a83724/basic1.htm#1006213
    Oracle lists support for:
    Net8 connection descriptor - Net8 is the old name for Oracle Net
    Thin-style sid name - what was quoted in the post to which I first responded.
    Thin-style sid name syntax has a colon between the port and the sid; thin-style service name syntax has a forward slash between the port and the service name. SIDs and service names are not the same thing, although they serve the same purpose in a URL (connecting you to the right instance) and often have the same value. However, a SID for a database is set at DB creation time, is unique to the DB, and cannot be changed easily. Multiple service names can be configured for a database, and they can easily be changed (if you're the DBA). Oracle is providing an additional leval of abstraction by moving to service names, to support additional features and choices. While many installations don't need all that and have in essence ignored the distinction bewteen SID and service name, some multi-database projects can benefit from it.
    >
    StuDerby, I think you should look into this a bit
    more. Your advice is far from optimal, IMO.
    Yeah, I could've taken the time to write a more generic, newbie friendly repsonse; instead, I lifted directly from the Oracle documentation that was cited earlier since newbies seem to have an aversion to reading documentation.

  • Oracle CEP JDBC Data Cartridge

    Hello,
    I'm trying to implement Oracle CEP JDBC Data Cartridge
    according to :
    http://docs.oracle.com/cd/E23943_01/apirefs.1111/e12048/datacartjdbc.htm#CIHCEFBH
    The problem is that it fails on deployment with following error :
    <Exception thrown from prepare method com.oracle.cep.cartridge.jdbc.JdbcCartridgeContext.checkCartridgeContextConfig.
    java.lang.AssertionError: java.lang.ClassNotFoundException: weblogic.jdbc.wrapper.PoolConnection
    I've added file that contains this class to classpath (com.bea.core.datasource6_1.10.0.0.jar) ,
    but get the same error .
    Any help would be appreciated .
    Regards,
    Dmitry

    Hello Wei Xiong,
    I have the same error when I trying to configure Oracle CQL Processor Table Source according to :
    http://docs.oracle.com/cd/E23943_01/dev.1111/e14301/processorcql.htm#CIHCCADG
    I've configured table source and had the same error on deployment :
    <The application context "check_entrance" could not be started: org.springframework.beans.FatalBeanException: Error in context lifecycle initialization; nested exception is com.bea.wlevs.ede.api.StatementException: Could not start rule [DBEventQuery] due to error: java.lang.ClassNotFoundException: weblogic.jdbc.wrapper.PoolConnection
    org.springframework.beans.FatalBeanException: Error in context lifecycle initialization; nested exception is com.bea.wlevs.ede.api.StatementException: Could not start rule [DBEventQuery] due to error: java.lang.ClassNotFoundException: weblogic.jdbc.wrapper.PoolConnection
         at com.bea.wlevs.spring.ApplicationContextLifecycle.onApplicationEvent(ApplicationContextLifecycle.java:145)
    It's look like a same issue.
    I've added zip file of my Eclipse project and config.xml of my CEP domain to e-mail.
    Thank you !
    Regards,
    Dmitry

  • JDBC configuration in 9.2.0.1

    Hi,
    In trying to use JDBC xa semantics in 9.2.0.1 i get a Resource Manager error during a xaresource.start(). Our Oracle configuration is customized in that we don't package components that are not needed. (We just need the database, jdbc and replication)
    If i install 9.2.0.1 from the Oracle supplied CD it works fine.
    What are the things i need to look at for JDBC configuration?
    I have looked at the ojdbc14.jar, the shared lib for OCI driver and some init.ora parameters like java_shared_pool.
    They are similar in both configurations.
    Any help appreciated.
    -giriraj

    Not having access to a 9i R2 database I have not been able to try this for myself. However, you may find this OTN article helpful: http://otn.oracle.com/oramag/webcolumns/2003/techarticles/poess_tablecomp.html
    Cheers, APC

  • Oracle 8i JDBC to connect to 9i DB?

    We are having a big Java application that uses Oracle8i as underlying DB. It uses Oracle 8i JDBC for that. Now, we have to extend this application with a module that writes certain things into another DB. However, this DB is on Oracle 9i.
    Q: Can we access a 9i DB using the 8i JDBC driver? If yes, is there a special configuration for the JDBC or the 9i DB?
    Note: switching the 9i to "8i compatibility mode" is not an option, since we use loads of 9i features in that DB from another application that uses the 9i JDBC driver!
    We tried it and we got loads of exceptions from the 8i JDBC driver.
    Any comment or hint is more than welcome - we are running out of time...

    Hi
    I am trying exactly the same thing and am not able to use Oracle8i JDBC for Oracle9i DB. Have u been able to do this? In case yes, please tell me how.
    Thanks
    Ashish

  • Error while creating a report that uses Oracle OCI JDBC connectivity

    Please let me know why my CR and LF characters are removed from my forum posting *****
    Hi,
    I was trying to create a report that uses Oracle OCI JDBC connectivity. I am using Eclipse3.4 download from "cr4e-all-in-one-win_2.0.2.zip".  I have successfully created a JDBC OCI connection.
    The connection parameters are given below:
    URL: jdbc:oracle:oci8:@xe
    Database: xe
    username: <userName>
    password: <password>
    I have tested the above connection in Data source Explorer and it works fine!!!
    But I am getting the following error when I drag-and-drop a table from the list of tables. Not sure what I am missing here?  Any help is highly appreciated.
    com.businessobjects.reports.jdbinterface.common.DBException: InvalidURLOrClassName
         at com.crystaldecisions.reports.queryengine.driverImpl.jdbc.JDBCConnection.Open(Unknown Source)
         at com.crystaldecisions.reports.queryengine.JDBConnectionWrapper.Open(SourceFile:123)
         at com.crystaldecisions.reports.queryengine.Connection.br(SourceFile:1771)
         at com.crystaldecisions.reports.queryengine.Connection.bs(SourceFile:491)
         at com.crystaldecisions.reports.queryengine.Connection.t1(SourceFile:2979)
         at com.crystaldecisions.reports.queryengine.Table.u7(SourceFile:2408)
         at com.crystaldecisions.reports.dataengine.datafoundation.AddDatabaseTableCommand.new(SourceFile:529)
         at com.crystaldecisions.reports.common.CommandManager.a(SourceFile:71)
         at com.crystaldecisions.reports.common.Document.a(SourceFile:203)
         at com.businessobjects.reports.sdk.requesthandler.f.a(SourceFile:175)
         at com.businessobjects.reports.sdk.requesthandler.DatabaseRequestHandler.byte(SourceFile:1079)
         at com.businessobjects.reports.sdk.JRCCommunicationAdapter.do(SourceFile:1163)
         at com.businessobjects.reports.sdk.JRCCommunicationAdapter.if(SourceFile:657)
         at com.businessobjects.reports.sdk.JRCCommunicationAdapter.a(SourceFile:163)
         at com.businessobjects.reports.sdk.JRCCommunicationAdapter$2.a(SourceFile:525)
         at com.businessobjects.reports.sdk.JRCCommunicationAdapter$2.call(SourceFile:523)
         at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
         at java.util.concurrent.FutureTask.run(Unknown Source)
         at com.businessobjects.crystalreports.designer.core.util.thread.ExecutorWithIdleProcessing$3.doWork(ExecutorWithIdleProcessing.java:182)
         at com.businessobjects.crystalreports.designer.core.util.thread.AbstractCancellableRunnable.run(AbstractCancellableRunnable.java:69)
         at com.businessobjects.crystalreports.designer.core.util.thread.PriorityTask.run(PriorityTask.java:75)
         at com.businessobjects.crystalreports.designer.core.util.thread.PriorityCompoundCancellableRunnable.runSubtask(PriorityCompoundCancellableRunnable.java:187)
         at com.businessobjects.crystalreports.designer.core.util.thread.PriorityProgressAwareRunnable.runSubtask(PriorityProgressAwareRunnable.java:90)
         at com.businessobjects.crystalreports.designer.core.util.thread.PriorityCompoundCancellableRunnable.doWork(PriorityCompoundCancellableRunnable.java:144)
         at com.businessobjects.crystalreports.designer.core.util.thread.AbstractCancellableRunnable.run(AbstractCancellableRunnable.java:69)
         at com.businessobjects.crystalreports.designer.core.util.thread.ExecutorWithIdleProcessing$IdleTask.run(ExecutorWithIdleProcessing.java:320)
         at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
         at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)
    Thanks
    Karthik
    Edited by: KARTHIK1 on Oct 14, 2009 9:38 PM

    Hi Ted,
    Thanks for the feedback. I was able to create a report in Creystal Reports Designer 2008 using OCI.  It is not allowing only in the Eclipse plugin. In our environment we are not allowed to user Oracle thin connections and ONLY OCI is allowed.
    1) Can you please let me know if there is a way to do this? 
    2) Will it allow data sources using native database driver?
    3) If so, can I use JRC to create these reports from a desktop java program?
    Thanks & Regards
    Karthik
    Edited by: KARTHIK1 on Oct 15, 2009 4:38 PM

  • Oracle OSB 11G. Unable to find Oracle Service Bus Configuration Page.

    Hi All,
    Sorry for the apparent silly question but I am studying and learning the product.
    I have the OSB 11G installed and running with a proxy service working and routing requests. The Oracle ESB documentation http://download.oracle.com/docs/cd/E21764_01/doc.1111/e15866/ui_ref.htm#i1327746 at chapter 4.4.2 New Oracle Service Bus Configuration Project Wizard
    Use this wizard to create an Oracle Service Bus configuration project. For configuration options, see Section 4.4.3, "Oracle Service Bus Configuration Page."
    4.4.3 Oracle Service Bus Configuration Page.
    I don't see the configuration page in anywhere in the left pane of the console. Am I missing something? The project creation works fine but I just don't see the configuration Wizard.
    Thanks.
    Regards
    Salvatore Ilardo

    The link which you are referring is for user interface objects in the Oracle Service Bus plug-ins and OSB plug-ins are used with OEPE (Oracle Enterprise Pack for Ecplise) for OSB development. OEPE is the only supported IDE for OSB development as of now.
    Remember, at a time, one and only one Oracle Service Bus Configuration project can be deployed in a OSB domain which may contain desired number of Oracle Service Bus Projects and that's why there is no provision of creating Oracle Service Bus Configuration Project in sbconsole GUI. In IDE, you may create many Oracle Service Bus Configuration Project and that's why it has a Oracle Service Bus Configuration Project Wizard.
    Regards,
    Anuj

  • Laptop keeps on rebooting after windows update configuration failure due to low disk space.

    Dear all, 
    My laptop keeps on restarting it self due to it cannot configure the windows update. I had tried all the solutions online including boot into safe mode, however none of this works as it keeps on going back to the windows configuration screen. I had no windows
    installation disc, i tried system repair and system restore, both also not working. 
    I know where my problems is, it is that I had turn on the quota management system in my c drive. Thus, it had limited my disk space. I suspect that the configuration failure is due to not enough disk space. 
    I am here to ask, anywhere i can start my windows without the update configuration step, or how did i turn off my quota management system without getting into the windows. I tried safe mode, it  still goes to the windows configuration screen and reboots
    again. 
    Please help, thanks. 

    Hi,
    You can access Advanced Boot Options by turning on your computer and pressing the F8 key before Windows starts.
    Then choose system restore to go back to a previous status if you have a restore point.
    Advanced startup options (including safe mode)
    http://windows.microsoft.com/en-in/windows/advanced-startup-options-including-safe-mode#1TC=windows-7
    Alex Zhao
    TechNet Community Support

  • Oracle 9i database configuration assisstant not running

    Hi All,
    My database is Oracle 9i.The configuration assisstant not running in this .can any body help?
    Reena

    Hi Reena, this got lost in the wrong forum. try the database forum
    Barry

  • Oracle 8i jdbc/Tomcat connection issues

    Tomcat 4.1.8
    Oracle 8i JDBC Driver
    I have been able to create the DataSource as a global resource and as a local resource inside the context of the application.
    The code hangs when it attempts to create a connection. I have been able to connect to the database and perform the necessary query in a standalone application to ensure that I actually can connect.
    JSP Code:
    <html>
    <head>
    <title>VTW App</title>
    </head>
    <body>
    <%
    vtw.VTWApp tst = new vtw.VTWApp();
    tst.init();
    %>
    <h2>Results</h2>
    <%= tst.getList() %>
    </body>
    </html>
    Java Code (Class called by JSP):
    package vtw;
    import javax.naming.*;
    import javax.sql.*;
    import java.sql.*;
    public class VTWApp {
    String list = "EMPTY";
    public void init() {
    try{
    Context ctx = new InitialContext();
    if(ctx == null )
    throw new Exception("Boom - No Context");
    System.out.println("Context Created ...");
    DataSource ds =
    (DataSource)ctx.lookup(
    "java:comp/env/jdbc/oracleDB");
    if (ds != null) {
              System.out.println("DataSource Created ...");
    Connection conn = ds.getConnection();
    System.out.println("Connection Pulled");
    if(conn != null) {
                   System.out.println("Connection Good");
                   Statement st = conn.createStatement();
                   String query = "";
                   query += "select grpid, to_char(min(dtlastendtime),'mm-dd-yyyy hh24:mi:ss') ";
                   query += "from calc_table where equipmentsernum in (";
                   query += "'888000','888001'";
                   query += ") group by grpid";
                   ResultSet rs = st.executeQuery(query);
                   if(rs != null) {
                        list = "";
                        while(rs.next()) {
                             list += (rs.getString(1) + "," + rs.getString(2));
                   rs.close();
                   conn.close();
                   System.out.println("Connection Closed");
              } else {
                   System.out.println("Connection Not Established");
    }catch(Exception e) {
    e.printStackTrace();
    public String getList() { return list; }
    }

    I figured out the issue ...
    In the server.xml file the resource & resource params needed to be modified..
    1. Set type to oracle.jdbc.pool.OracleDataSource
    2. Set factory to oracle.jdbc.pool.OracleDataSourceFactory
    3. In the Java code cast the context lookup to an OracleDataSource instead of a java.sql.DataSource
    Oracles DataSource does not subclass the jdbc DataSource for its OracleDataSource class everything works fine now.
    <Resource name="jdbc/mydb" scope="Shareable" type="oracle.jdbc.pool.OracleDataSource"/>
    <ResourceParams name="jdbc/mydb">
    <parameter>
    <name>validationQuery</name>
    <value></value>
    </parameter>
                   <parameter>
                        <name>factory</name>
                        <value>oracle.jdbc.pool.OracleDataSourceFactory</value>
                   </parameter>
    <parameter>
    <name>driverClassName</name>
    <value>oracle.jdbc.driver.OracleDriver</value>
    </parameter>
    <parameter>
         <name>url</name>
         <value>jdbc:oracle:thin:@server.company.com:1521:dbname</value>
    </parameter>
    <parameter>
    <name>password</name>
    <value>guest</value>
    </parameter>
                   <parameter>
                        <name>maxWait</name>
                        <value>10000</value>
                   </parameter>
                   <parameter>
                        <name>maxActive</name>
                        <value>100</value>
                   </parameter>
    <parameter>
    <name>user</name>
    <value>guest</value>
    </parameter>
    <parameter>
    <name>maxIdle</name>
    <value>2</value>
    </parameter>
    </ResourceParams>

  • Help on Oracle streams 11g configuration

    Hi Streams experts
    Can you please validate the following creation process steps ?
    What is need to have streams doing is a one way replication of the AR
    schema from a database to another database. Both DML and DDL shall do
    the replication of the data.
    Help on Oracle streams 11g configuration. I would also need your help
    on the maintenance steps, controls and procedures
    2 databases
    1 src as source database
    1 dst as destination database
    replication type 1 way of the entire schema FaeterBR
    Step 1. Set all databases in archivelog mode.
    Step 2. Change initialization parameters for Streams. The Streams pool
    size and NLS_DATE_FORMAT require a restart of the instance.
    SQL> alter system set global_names=true scope=both;
    SQL> alter system set undo_retention=3600 scope=both;
    SQL> alter system set job_queue_processes=4 scope=both;
    SQL> alter system set streams_pool_size= 20m scope=spfile;
    SQL> alter system set NLS_DATE_FORMAT=
    'YYYY-MM-DD HH24:MI:SS' scope=spfile;
    SQL> shutdown immediate;
    SQL> startup
    Step 3. Create Streams administrators on the src and dst databases,
    and grant required roles and privileges. Create default tablespaces so
    that they are not using SYSTEM.
    ---at the src
    SQL> create tablespace streamsdm datafile
    '/u01/product/oracle/oradata/orcl/strepadm01.dbf' size 100m;
    ---at the replica:
    SQL> create tablespace streamsdm datafile
    ---at both sites:
    '/u02/oracle/oradata/str10/strepadm01.dbf' size 100m;
    SQL> create user streams_adm
    identified by streams_adm
    default tablespace strepadm01
    temporary tablespace temp;
    SQL> grant connect, resource, dba, aq_administrator_role to
    streams_adm;
    SQL> BEGIN
    DBMS_STREAMS_AUTH.GRANT_ADMIN_PRIVILEGE (
    grantee => 'streams_adm',
    grant_privileges => true);
    END;
    Step 4. Configure the tnsnames.ora at each site so that a connection
    can be made to the other database.
    Step 5. With the tnsnames.ora squared away, create a database link for
    the streams_adm user at both SRC and DST. With the init parameter
    global_name set to True, the db_link name must be the same as the
    global_name of the database you are connecting to. Use a SELECT from
    the table global_name at each site to determine the global name.
    SQL> select * from global_name;
    SQL> connect streams_adm/streams_adm@SRC
    SQL> create database link DST
    connect to streams_adm identified by streams_adm
    using 'DST';
    SQL> select sysdate from dual@DST;
    SLQ> connect streams_adm/streams_adm@DST
    SQL> create database link SRC
    connect to stream_admin identified by streams_adm
    using 'SRC';
    SQL> select sysdate from dual@SRC;
    Step 6. Control what schema shall be replicated
    FaeterBR is the schema to be replicated
    Step 7. Add supplemental logging to the FaeterBR schema on all the
    tables?
    SQL> Alter table FaeterBR.tb1 add supplemental log data
    (ALL) columns;
    SQL> alter table FaeterBR.tb2 add supplemental log data
    (ALL) columns;
    etc...
    Step 8. Create Streams queues at the primary and replica database.
    ---at SRC (primary):
    SQL> connect stream_admin/stream_admin@ORCL
    SQL> BEGIN
    DBMS_STREAMS_ADM.SET_UP_QUEUE(
    queue_table => 'streams_adm.FaeterBR_src_queue_table',
    queue_name => 'streams_adm.FaeterBR_src__queue');
    END;
    ---At DST (replica):
    SQL> connect stream_admin/stream_admin@STR10
    SQL> BEGIN
    DBMS_STREAMS_ADM.SET_UP_QUEUE(
    queue_table => 'stream_admin.FaeterBR_dst_queue_table',
    queue_name => 'stream_admin.FaeterBR_dst_queue');
    END;
    Step 9. Create the capture process on the source database (SRC).
    SQL> BEGIN
    DBMS_STREAMS_ADM.ADD_SCHEMA_RULES(
    schema_name =>'FaeterBR',
    streams_type =>'capture',
    streams_name =>'FaeterBR_src_capture',
    queue_name =>'FaeterBR_src_queue',
    include_dml =>true,
    include_ddl =>true,
    include_tagged_lcr =>false,
    source_database => NULL,
    inclusion_rule => true);
    END;
    Step 10. Instantiate the FaeterBR schema at DST. by doing export
    import : Can I use now datapump to do that ?
    ---AT SRC:
    exp system/superman file=FaeterBR.dmp log=FaeterBR.log
    object_consistent=y owner=FaeterBR
    ---AT DST:
    ---Create FaeterBR tablespaces and user:
    create tablespace FaeterBR_datafile
    '/u02/oracle/oradata/str10/FaeterBR_01.dbf' size 100G;
    create tablespace ws_app_idx datafile
    '/u02/oracle/oradata/str10/FaeterBR_01.dbf' size 100G;
    create user FaeterBR identified by FaeterBR_
    default tablespace FaeterBR_
    temporary tablespace temp;
    grant connect, resource to FaeterBR;
    imp system/123db file=FaeterBR_.dmp log=FaeterBR.log fromuser=FaeterBR
    touser=FaeterBR streams_instantiation=y
    Step 11. Create a propagation job at the source database (SRC).
    SQL> BEGIN
    DBMS_STREAMS_ADM.ADD_SCHEMA_PROPAGATION_RULES(
    schema_name =>'FaeterBR',
    streams_name =>'FaeterBR_src_propagation',
    source_queue_name =>'stream_admin.FaeterBR_src_queue',
    destination_queue_name=>'stream_admin.FaeterBR_dst_queue@dst',
    include_dml =>true,
    include_ddl =>true,
    include_tagged_lcr =>false,
    source_database =>'SRC',
    inclusion_rule =>true);
    END;
    Step 12. Create an apply process at the destination database (DST).
    SQL> BEGIN
    DBMS_STREAMS_ADM.ADD_SCHEMA_RULES(
    schema_name =>'FaeterBR',
    streams_type =>'apply',
    streams_name =>'FaeterBR_Dst_apply',
    queue_name =>'FaeterBR_dst_queue',
    include_dml =>true,
    include_ddl =>true,
    include_tagged_lcr =>false,
    source_database =>'SRC',
    inclusion_rule =>true);
    END;
    Step 13. Create substitution key columns for äll the tables that
    haven't a primary key of the FaeterBR schema on DST
    The column combination must provide a unique value for Streams.
    SQL> BEGIN
    DBMS_APPLY_ADM.SET_KEY_COLUMNS(
    object_name =>'FaeterBR.tb2',
    column_list =>'id1,names,toys,vendor');
    END;
    Step 14. Configure conflict resolution at the replication db (DST).
    Any easier method applicable the schema?
    DECLARE
    cols DBMS_UTILITY.NAME_ARRAY;
    BEGIN
    cols(1) := 'id';
    cols(2) := 'names';
    cols(3) := 'toys';
    cols(4) := 'vendor';
    DBMS_APPLY_ADM.SET_UPDATE_CONFLICT_HANDLER(
    object_name =>'FaeterBR.tb2',
    method_name =>'OVERWRITE',
    resolution_column=>'FaeterBR',
    column_list =>cols);
    END;
    Step 15. Enable the capture process on the source database (SRC).
    BEGIN
    DBMS_CAPTURE_ADM.START_CAPTURE(
    capture_name => 'FaeterBR_src_capture');
    END;
    Step 16. Enable the apply process on the replication database (DST).
    BEGIN
    DBMS_APPLY_ADM.START_APPLY(
    apply_name => 'FaeterBR_DST_apply');
    END;
    Step 17. Test streams propagation of rows from source (src) to
    replication (DST).
    AT ORCL:
    insert into FaeterBR.tb2 values (
    31000, 'BAMSE', 'DR', 'DR Lejetoej');
    AT STR10:
    connect FaeterBR/FaeterBR
    select * from FaeterBR.tb2 where vendor= 'DR Lejetoej';
    Any other test that can be made?

    Check the metalink doc 301431.1 and validate
    How To Setup One-Way SCHEMA Level Streams Replication [ID 301431.1]
    Oracle Server Enterprise Edition - Version: 10.1.0.2 to 11.1.0.6
    Cheers.

Maybe you are looking for

  • Where is the search field in Safari 6.0?

    I have completed the Apple Software update today of several programs, but have not yet updated to MT. Lion.  My Safari browser now seems to be lacking a search box/field in the upper right.  I think that prior to the update there was such a box in th

  • HT1430 how can i reset my ipod touch when its disabled ?

    i dont remember my passcode

  • Update of a table via a form

    I created a form with two blocks. one of them is a select block for the user (not based on a database table) and the other one contains the result (through given parameters from the first block[the user's query]). after the execution of the query and

  • ( customer expected price)

    Sap R/3 Customer expected price  formula 9 is used, with stastical l entry. system compares expected price of a line item with net price computed by system .if system net price is not with value range 0.05 customer expected price then item is blocked

  • Advice needed on upgrading to Yosemite and SSD simultaneously

    I am upgrading my early 2011 MacBook Pro replacing my 320gb HDD with a 500GB SSD drive and upgrading RAM from 4gb to 16gb. The question is, should I do a clean install of Yosemite to the SSD and use migration assistant to recover apps and data from T