How to configure informix connection pool in sun-one appserver 7

Hello,
Anybody knows , How to configure informix connection pool properties in sun-one appserver 7?
Thanks in advance.

Actually,it couldn't get some advice in here.But now,I known how to configure it,I expended 2 days to search and test it.Follow :
jdbc class:com.informix.jdbcx.IfxDataSource
serverName=(INFORMIXSERVER)
portNumber=1526(default)
IfxIFXHOST=(host ip)
databaseName=(your dbname)
user=(your username)
password=(your pwd)
attention:configure right transaction and userthreads in your informix sever
Hope helpful to someone!

Similar Messages

  • Replace Quotes, Connection Pooling, and Sun Web Server with MySQL, Oracle

    This is code I use to insert data into my MySQL and Oracle databases.
    I takes care of quotes and shows use of context, i.e. when you use Sun Web Server's
    ConnectionPooling. This code works. Feel free to reply if you have questions on how to set up connection pooling using Sun Web Server 6.1SP - it took quite a long time to learn and I couldn't find much information throughout the web, so I hope this helps...
    This is not a question and I am not looking for an answer, but please post comments or suggestions.
    dailysun
    This is in one class where I have a hashtable containing the
    column name / value pairs that I want to enter into my table.
    This class simply creates the SQL string from the values in the
    hashtable. It then passes that hashtable including the database
    name to a class which executes that sql statement (second code
    portion).
    /* Insert data into sf_parts. Create the column strings from
             * the provided hash table. Be sure to parse out hash elements which
             * are used for the createTemplate process
            StringBuffer values = new StringBuffer();
            StringBuffer fields = new StringBuffer();
            Enumeration keys = fieldHash.keys();
            while(keys.hasMoreElements()){
                Object currentKey = keys.nextElement();
                    String fieldValue = (String) fieldHash.get(currentKey);
                    if(values.length() >0){
                        values.append(",");
                    values.append("'"+fieldValue.replaceAll("'","''")+"'"); // Takes care of quotes and various other special characters!
                    if(fields.length() >0){
                        fields.append(",");
                    fields.append(currentKey);
            sql = "INSERT INTO myTable (" + fields.toString() + ") VALUES (" + values.toString() + ");";
            String insertResult = caq.getInsertDelete(sql,"myDatabaseName"); // your database name is defined in web.xml and sun-web.xml when you use Sun Web Server's Connection Pooling.
            returnValue += "<br><br><b>Rows inserted into table(myTable): </b>" + insertResult + "<br>\n";
            And, like I describe above, this method executes the sql statement.
         * Takes care of insert, update and delete requests.
         * Must have set both dbName as well as the sql String.
         * Will return number of rows affected as String.
         * @return String Number of rows affected
         * @exception SQLException
         * @exception Exception
        public String getInsertDelete() {
            checkData(); // this simply checks if the variables dbName and sql are not empty ;-)
            InitialContext initContext = null;
            int rv = 0;
            try{
                // Get connection from configured pool
                initContext = new InitialContext();
                source = (DataSource) initContext.lookup("java:comp/env/jdbc/" + dbName); // I have this set up in web.xml and sun-web.xml (I use Sun Web Server 6.1SP which does connection pooling for me)
                conn = source.getConnection();
                if(conn != null){
                    stmt = conn.createStatement();
                    rv = stmt.executeUpdate(sql);
            }catch (SQLException e){
                // do something
            }catch (Exception e){
                // do something
            }finally{
                try{
                    stmt.close();
                }catch(Exception e){
                    // do something
                try{
                    conn.close();
                }catch(Exception e){
                    // do something
                try{
                    initContext.close();
                }catch(Exception e){
                    // do something
            return rv+"";
        }  

    This is code I use to insert data into my MySQL and
    Oracle databases.
    I takes care of quotes and shows use of context, i.e.
    when you use Sun Web Server's
    ConnectionPooling. This code works. Feel free to
    reply if you have questions on how to set up
    connection pooling using Sun Web Server 6.1SP - it
    took quite a long time to learn and I couldn't find
    much information throughout the web, so I hope this
    helps...
    This is not a question and I am not looking for an
    answer, but please post comments or suggestions.Using prepared statements would mean that you wouldn't have to worry about quotes.
    You should be closing the result set.
    You are handling all fields as strings. That won't work with time fields and might not work for numeric fields.
    Presumably most of your variables are member variables. They should be local variables because that is the scope of the usage.
    You must do something with the exceptions.
    Hashtables although convienent mean that problems with usage can only be resolved at run time rather than compile time.

  • How to change the connection pool configuration on OC4J?

    Hi everybody,
    I am developing an application with JDeveloper which is running on an OC4J standalone server, we have 2 enviroments, the develop server and the server of the client, and the data base connection configurations are differents.
    The problem is that if we try to deploy the application (we have deploy on the develop server) on the client server and try to change the connection pool configuration the application cannot connect to the data base, we need to re-build the project with the client connection pool configuration.
    We tried to change the configuration on the enterprise manager of the OC4J, on "JDBC Resources" panel, and the test the connection is ok, but when try to access to the application we get an Exception. After that we try to do that changing the parameters from the datasources.xml file on the application, but the result is the same.
    How can we change the DataBase configuration without re-build the project?
    Thanks very much
    Tony

    Meaning you have created just the empty data-sources.xml and not configured any Connection Pool and DataSource in JDev?
    In Oracle AS 10.1.3 you have two ways to do this:
    1. Use JDev and configure the data-sources.xml (Context Menu -> Properties)
    2. In Oracle AS: Select application -> Administration -> Services -> JDBC Resources -> Create Pool and Create DataSource
    --olaf                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • How to create a connection pooling in Netbeans 6.0 using the oracle driver

    hi all,
    I am using Netbeans 6.0. Apache Tomcat 6.0.14 server, oracle 9i.
    I tried to create a connection pooling using tomcat web server.
    I have included the following code in context.xml and web.xml.
    CONTEXT.XML:
    <?xml version="1.0" encoding="UTF-8"?>
    <Context path="/network1">
    <Resource name="jdbc/myoracle"
    auth="Container"
    type="javax.sql.DataSource"
    username="scott"
    password="tiger"
    factory="BasicDataSourceFactory"
    driverClassName="oracle.jdbc.OracleDriver"
    url="jdbc:odbc:thin:@127.0.0.1:1521:mydb"
    maxActive="20"
    maxIdle="10"
    maxwait="-1"/>
    </Context>
    WEB.XML:
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
    <session-config>
    <session-timeout>
    30
    </session-timeout>
    </session-config>
    <welcome-file-list>
    <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>
    <resource-ref>
    <description>Oracle Datasource example</description>
    <res-ref-name>jdbc/myoracle</res-ref-name>
    <res-type>javax.sql.DataSource</res-type>
    <res-auth>Container</res-auth>
    </resource-ref>
    </web-app>
    After that i have included the following JDBC driver's jar files in the $Catalina_Home/lib folder.
    classes 111.jar,
    classes 111_g.jar
    classes12.jar
    classes 12_g.jar
    classes12dms.jar
    classes12dms_g.jar
    nls_charset11.jar
    nls_charset12.jar
    ocrs12.jar
    ojdbc14.jar
    ojdbc14_g.jar
    Then i stop the tomcat web server and start it again.
    In jsp page i have included the following code:
    Context ctx=new InitialContext();
    Context envctx=(Context)ctx.lookup("java:comp:env");
    DataSource ds=(DataSource)envctx.lookup("jdbc/myoracle");
    Connection con=ds.getConnection(); ----->(In this line an error occured that Connection class cannot be found.)
    please help me how to create a connection pooling and rectify the error in conneciton.
    Thanks in advance

    Please refer
    http://www.netbeans.org/kb/60/web/customer-book.html

  • How to test if connection pool is set up correctly in WL 7 SP 7

    Hi all,
    2 questions.
    1) how do i test if the connection pool i set is working? in the testing tab of the jdbc connection pool in the console page, there is a Test Table Name, i entered 'dual' in the text field. After i clicked apply, there is no indication if i set it up correctly.
    2)After i configure the connection pool, do i need to configure the data sources?

    Could you please try using a "Test_When" statement?
    Karthik

  • Configuring JCo3 Connection Pool with single sign on on non SAP Java server

    Hi Everyone,
    i have configured a connection pool on JBoss as per JCo3 Documentation and is working great.
    Now I need help to configure this connection pool with single sign on so that RFc on SAP ECC systems are executed using end users credential rather than using single user name password used to configure JCo connection pool.
    On SAP Java stack I am sure its possible within Java WebDynpro    and i assume using JCA resource adapter. But what if we don't want to use SAP Java App server.
    Any help will be appreciated.
    Thanks,
    Divyakumar Jain

    Eason, 你好!
    I have exactly the same problem.  Did you find a solution to this problem?  If so, please let me know!

  • How to use JDBC Connection Pools in a standalone application?

    Hi, there,
    I have a question about how to use JDBC Connection Pools in an application. I know well about connection pool itself, but I am not quite sure how to keep the pool management object alive all the time to avoid being destroyed by garbage collection.
    for example, at the website: http://www.developer.com/java/other/article.php/626291, there is a simple connection pool implementation. there are three classes:JDBCConnection, the application's gateway to the database; JDBCConnectionImpl, the real class/object to provide connection; and JDBCPool, the management class to manage connection pool composed by JDBCConnectionImpl. JDBCPool is designed by Singleton pattern to make sure only one instance. supposing there is only one client to use connection for many times, I guess it's ok because this client first needs instantiate JDBCPool and JDBCConnectionImpl and then will hold the reference to JDBCPool all the time. but how about many clients want to use this JDBCPool? supposing client1 finishes using JDBCPool and quits, then JDBCPool will be destroyed by garbage collection since there is no reference to it, also all the connections of JDBCConnectionImpl in this pool will be destroyed too. that means the next client needs recreate pool and connections! so my question is that if there is a way to keep pool management instance alive all the time to provide connection to any client at any time. I guess maybe I can set the pool management class as daemon thread to solve this problem, but I am not quite sure. besides, there is some other problems about daemon thread, for example, how to make sure there is only one daemon instance? how to quit it gracefully? because once the whole application quits, the daemon thread also quits by force. in that case, all the connections in the pool won't get chance to close.
    I know there is another solution by JNDI if we develop servlet application. Tomcat provides an easy way to setup JNDI database pooling source that is available to JSP and Servlet. but how about a standalone application? I mean there is no JNDI service provider. it seems a good solution to combine Commons DBCP with JNID or Apache's Naming (http://jakarta.apache.org/commons/dbcp/index.html). but still, I don't know how to keep pool management instance alive all the time. once we create a JNDI enviroment or naming, if it will save in the memory automatically all the time? or we must implement it as a daemon thread?
    any hint will be great apprieciated!
    Sam

    To my knoledge the pool management instance stays alive as long as the pool is alive. What you have to figure out is how to keep a reference to it if you need to later access it.

  • How to implement a connection pooling in servlet

    hi all,
    how to implement a connection pooling in servlet.i want to know how to implement it in tomcat in a struts based environment.
    any input to the topic is appreciated.
    Thanks
    Sudha

    Take a look at JNDI
    http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-examples-howto.html

  • How to configure BT connection from PDA?

    Hello :)
    PDA cannot find the ActiveSync service, though Windows Mobile Device Center 6.1 is running, and COM port is configured appropriately.
    PDA HTC P3300 Artemis-WinMob 5.0, USB Bluettoth adapter, last version 7.10.10
    in IVT BlueSoleil works fine
    Manual *"How to configure a connection from the PDA (Windows Mobile 6) to the Windows Mobile Device Center"* not help
    Windows 7 64bit

    My HTC Windows Mobile 6.1 phone (not your model) in combination with Windows7 x64 and Windows Mobile Device Center works just fine for me with Bluetooth stack v7.10.10 (T). Ensure that you use the suitable x64 bit version of the Windows Mobile Device Center.
    Here are my links:
    http://www.microsoft.com/windowsmobile/en-us/downloads/microsoft/device-center-download.mspx
    http://www.microsoft.com/downloads/details.aspx?FamilyId=4F68EB56-7825-43B2-AC89-2030ED98ED95&displaylang=en

  • How Do I enable gzip compression on Sun One Web Server 6.0

    How Do I enable gzip compression on Sun One Web Server 6.0

    Hi,
    Sun ONE webserver 6.0 is over 5 years old and is reaching end of support life. Please consider upgrading to webserver 6.1sp5 which is free:
    http://www.sun.com/download/products.xml?id=434aec1d
    or else the preview version of WebServer 7.0 (also free)):
    http://www.sun.com/download/products.xml?id=446518d5
    For webserver 6.1, the docs for setting up compression are at:
    http://docs.sun.com/source/819-0130/agcontnt.html#wp1019634
    and
    http://docs.sun.com/source/817-6252/npgnsapi.html
    Hope this helps

  • How to deploy a WAR file to Sun One Portal Server

    Would someone please tell me the instruction of how to deploy a WAR file to Sun One Portal Server 6.2. Thank you.

    I would advise against this. We tried that and it totally hosed the server.xml file and took our staging portal server down.
    I have no idea what was "in" the server.xml or other files, but trying to deploy a .war file using the WS admin interface hosed portal server's settings.

  • How to find total in-use connection of a connection pool in Sun apps 8.1 ur

    Hi
    Thank you for reading my post.
    how i can find total open (in-use)connection of a connection pool ?
    sometimes my application take some longer time to do an specefic job , now i want to see how much connection of the pool is open and in use
    thanks

    Hi,
    Sun app.server provides monitoring facility using which we can find how many connections are in use, how many clients are in wait-queue etc.,
    You can refer the following URL of
    Sun Java System Application Server 8 - Administration guide.
    http://docs.sun.com/app/docs/doc/819-2554/6n4r8s7ti?a=view
    for enabling monitoring and getting monitoring values for a particular conn. pool
    Thanks,
    -Jagadish

  • How to Troubleshoot the Connection Pool Exception?

    Dear Oracle Gurus, very good afternoon to you.
    I'm looking forward for some tips/troubleshoting guide to escape from the below exception, that occres very frequently to one of application that 100+ users will login from different locations & work on and update the data and save their work, where all in sudden they can't acces the application and it gets down.
    Most of the times in the server log I observed below.
    weblogic.jdbc.extensions.PoolLimitSQLException: weblogic.common.resourcepool.ResourceLimitException: No resources currently available in pool RemoteDesktop.main to allocate to applications, please increase the size of the pool and retry..
    Please help me on, how to overcome this kind of exception.
    In Weblogi c server I see below kind of Warnings.
    If you set the buffer size to zero in a servlet, it would fail to respond and would initiate an infinite loop in the server. WebLogic Server would ultimately display a Errors:
    ExecuteThread: '157' for queue: 'weblogic.kernel.Default' has been busy for "633" seconds working on the request "Http Request: : ../updates/process_manager.jsp", which is more than the configured time (StuckThreadMaxTime) of "600" seconds.
    I searched over google for this kind of error, See otherusers posted the same kind of errors but didn't have any positive replies to troubleshoot this issue.
    I also got Oracle Dev link on Weblogic version upgrade product where they fixed similar kind of error it seems. Which is shown below.
    http://docs.oracle.com/cd/E13222_01/wls/docs61/notes/bugfixes2.html -- BUG # CR106186
    details:
    "Suspend Checker Thread" prio=10 tid=0x23eb90 nid=0xfec runnable
    <May 14, 2003 10:53:34 AM PDT> <Warning> <WebLogicServer> <000337>
    <ExecuteThread: '10' for queue: 'default' has been busy for "1,181" seconds working on the request "Http Request: servlet_uri", which is more than the configured time (StuckThreadMaxTime) of "600" seconds.>
    This problem was solved with a code fix.
    Looking forward for some help, Thank you inadvance.
    FYI..
    I'm using oracle thin driver JDBC connection/Weblogic 8.1
    Edited by: user1072948 on Apr 26, 2012 11:55 AM

    I agree that looking into the number of connections that you have open when you see
    weblogic.jdbc.extensions.PoolLimitSQLException: weblogic.common.resourcepool.ResourceLimitException: No resources currently available in pool RemoteDesktop.main to allocate to applications, please increase the size of the pool and retry..
    would be a good idea; but I would suggest that you don't increase without thinking about the consequences. I would look more closely at what the connections to the database are doing, for instance, how long are the connection being left open for? What are the queries that are being run? Should you expect to see all the connections in the connection pool being used? What is the current connection pool limit? Are you simply going to increase the number of connections to find that they are also waiting? What is the load on the database at the time?
    It's the other error that you say you see
    ExecuteThread: '157' for queue: 'weblogic.kernel.Default' has been busy for "633" seconds working on the request "Http Request: : ../updates/process_manager.jsp", which is more than the configured time (StuckThreadMaxTime) of "600" seconds.
    What does this JSP do? Why would this be busy for so long? Is it related to the previous exception that you have? I'd ask you delevelopment team to look into this.
    In short, it sounds like you have load issues on your server(s) and a careful tuning of the system after a full analysis (thread dumps, heap profiling, connection pool monitoring and code review) would probably be beneficial. It may be that restricting the thread pool may help, it may be that increasing the connection pool would help. I'd not plump for a quick fix here.

  • How do i use Connection pool in JSP pages

    Hey everyone,
    I am using a connection pool in my web application. I am using DbConnectionBroker from Javaexchange.com. It has a class that creates a connection pool available for the servlets. I am trying to figure out that how to use connection pool within the JSP pages if I want to connect to the database. In the servlets i am using DBConnectionBroker pool = (DbConnectionBroker) getServletContext().getAttribute("dbPool") to get database connection. How Can i use this in JSP page to get a db connection.
    Thanks

    If the reference to the connection pool is already stored as an ServletContex attribute, try:
    <jsp:useBean id="dbPool" scope="application" class="com.javaexchange.dbConnectionBroker" />
    <%
    Connection con = dbPool.getConnection();
    %>

  • How can i use connection pool within the sqlj?

    hello
    i am a beginner to sqlj,i find all of the sample code from the oracle DON'T use connectionpool,they only write the database url to "connection.properties" file,but i think in the production environment we should use the connectionpool to optimise the querying,i usually use the weblogic connection pool.
    how can i use the connection pool within the sqlj?
    thank you very much!

    Im not sure if I understand. :)
    English is not my best language...
    Looking up the connection again? Do you mean I have to create new DataSource object and bind it again to ServletContext?

Maybe you are looking for

  • Problem in transferring file(presentation server) contents to internl table

    Hi Experts,       My requirement is to upload a file from presentation server and get the contents into an internal table then I need to update bespoke table based on the values of the internal table. I tried using both funtion module : WS_UPLOAD and

  • Retrieving free space in oracle 8i

    hi, i am having 30 gb oracle 8.1.7.2 database. by the weekend we are gonna purge around 60% of data from it. we want to use the freed space for new object. the downtime avaiable for app. is very less. so we can't go with exp/imp to retrieve free spac

  • How to extend sales views extension for purchase material?

    Dear MM experts, pl let us know how purchase material master is extended with sales views. we have defined material for purchase views only, now we have requirement of sales views for the same material. Please let us how this can be done. Thanks in a

  • I can't import any files from itunes... the click and drag isn't working...

    I've tried clicking and dragging my mp3 from the desktop, from the finder, and straight from itunes, but i can't get it to be in garageband... at all... I feel like i'm doing the same thing i was doing even just earlier today, but it isn't working an

  • MacBook Pro 13" Battery won't charge.

    The (relatively new) charger works fine and powers the laptop fine - a green light is on when connected but the battery won't charge. Here is the information. Can anybody help? Battery Information:   Model Information:   Serial Number:          W0031