JDBC on Servlets

The following worked on my machine as a java console, but tomcat does not seem to like ir. It excepts on classnotfound
com.mysql.jdbc.Driver
help?
try
Class.forName("com.mysql.jdbc.Driver").newInstance();
catch (Exception e)
System.out.println(e.toString());
// localhost192.168.1.101
Connection conn =
DriverManager.getConnection("jdbc:mysql://localhost:3306?" +
"user=root&password=secret");

JDBC on Servlets ...is undesirable for most (professional) projects.
try to keep db access code out of your web app if
possible. It's just good conventionAt best that statement is confusing.
I can only guess that you were suggesting that a database layer should be used rather than putting the JDBC code directly in the servlet code.

Similar Messages

  • Servlets/JDBC vs. servlets/EJB performance comparison/benchmark

    I have a PHB who believes that EJB has no ___performance___ benefit
    against straightforward servlets/JSP/JDBC. Personally, I believe that
    using EJB is more scalable instead of using servlets/JDBC with
    connection pooling.
    However, I am at a lost on how to prove it. There is all the theory, but
    I would appreciate it if anyone has benchmarks or comparison of
    servlets/JSP/JDBC and servlets/JSP/EJB performance, assuming that they
    were tasked to do the same thing ( e.g. performance the same SQL
    statement, on the same set of tables, etc. ).
    Or some guide on how to setup such a benchmark and prove it internally.
    In other words, the PHB needs numbers, showing performance and
    scalability. In particular, I would like this to be in WLS 6.0.
    Any help appreciated.

    First off, whether you use servlets + JDBC or servlets + EJB, you'll
    most likely spend much of your time in the database.
    I would strongly suggest that you avoid the servlets + JDBC
    architecture. If you want to do straight JDBC code, then it's
    preferable to use a stateless session EJB between the presentation layer
    and the persistence layer.
    So, you should definitely consider an architecture where you have:
    servlets/jsp --> stateless session ejb --> JDBC code
    Your servlet / jsp layer handles presentation.
    The stateless session EJB layer abstracts the persistence layer and
    handles transaction demarcation.
    Modularity is important here. There's no reason that your presentation
    layer should be concerned with your persistence logic. Your application
    might be re-used or later enhanced with an Entity EJB, or JCA Connector,
    or a JMS queue providing the persistence layer.
    Also, you will usually have web or graphic designers who are modifying
    the web pages. Generally, they should not be exposed to transactions
    and jdbc code.
    We optimize the RMI calls so they are just local method calls. The
    stateless session ejb instances are pooled. You won't see much if any
    performance overhead.
    -- Rob
    jms wrote:
    >
    I have a PHB who believes that EJB has no ___performance___ benefit
    against straightforward servlets/JSP/JDBC. Personally, I believe that
    using EJB is more scalable instead of using servlets/JDBC with
    connection pooling.
    However, I am at a lost on how to prove it. There is all the theory, but
    I would appreciate it if anyone has benchmarks or comparison of
    servlets/JSP/JDBC and servlets/JSP/EJB performance, assuming that they
    were tasked to do the same thing ( e.g. performance the same SQL
    statement, on the same set of tables, etc. ).
    Or some guide on how to setup such a benchmark and prove it internally.
    In other words, the PHB needs numbers, showing performance and
    scalability. In particular, I would like this to be in WLS 6.0.
    Any help appreciated.--
    Coming Soon: Building J2EE Applications & BEA WebLogic Server
    by Michael Girdley, Rob Woollen, and Sandra Emerson
    http://learnweblogic.com

  • Which tutorials may you suggest for JDBC and servlets?

    Hello, i would to learn about JDBC and servlets.
    May you please suggest me a good tutorial(e.g.post me a link) in order to study for JDBC and servlets?
    e.g. How to make a servlet etc.
    Thanks, in advance!

    I agree with PhHein, it's best to learn one technology and then the other. (Just my two cents, but start with JDBC from a simple standalone application, then when that is working, try to tackle Servlets, since you will need to also learn how to get them working in a container like Tomcat).
    Here is a tutorial that has both concepts in it at the same time. Site is down now, but is usually up. http://www.roseindia.net/jdbc/jdbcconnectivity.shtml
    Also, you will eventually want to download a J2EE container such as Tomcat or Jboss.
    - Saish

  • JDBC using Servlets!!!!!!Hurry up!

    Hi,
    MySelf Savdeep Vasudeva,Presently I am involved in a project using JDBC-ODBC Bridge in which I want to connect a database table to a HTML Page using Java Servlets.When I fill the form on the HTML Page using numeric data in all my variables,it works quite good and the query is executed.Consequently the data of the person who has filled in the form is displayed.But when I want to change one of the numeric variables(parameter variable) to a String by also making the data type change in my table from numeric to character.The query is not executed at all and It gives the exception message.Kindly help me that how should I make a query in the Java Servlets using the String Variables in the condition.Presently I am only Limited to numeric
    variables.Waiting for a quick response from your side.
    Regards,
    Savdeep Vasudeva.
    E-mail: [email protected]

    Savdeep,
    it would really help, if u posted some part of the erroneous code. anyway, u say u have changed the datatype in ur table to string, but while receiving the parameters, what ru using?
    for integers values u would have been using something like: rs.getInt(col index);
    whereas to get a string value u have to use:
    rs.getString(col index);
    are u making this change in ur code???
    keep progRamming...
    -satyen

  • JDBC thru Servlets

    Hi there,
    I have a HTML form, which will submit some details to a servlet. In that Servlet i am connecting to a Database(thru JDBC) to insert those form details. I was writing my code in doPost() method of my Servlet. I used to Open the DB connection and close it when come out of the servlet(i used to redirect to a JSP thru RequestDispatcher Object). Theform will be used by many clinets, so there is lot of DB connection opening and closing going to happen.
    But recently i came to know instead of writing DB opening and closing code in doPost(), we can write it in init(), so that only one connection will be made and it can be used for all the threads of the servlets.
    My doubt,
    If it is so, where should i write my DB connection close method()?
    Does anybody have a sample code of this, ?.
    Thanx in advance
    javaIdiot

    If you write the connection establishment code in the init() the close should go in the destroy() method.
    This way there will be one connection per servlet instance instead of connection per request. But at a given time there might be multiple connection becouse there can be multiple servlet instances in memory.
    The best solution would be using a connection pool and take a connection from the pool when you need and release it when you dont need it.
    Take a look at the apache-commons-dbcp project
    http://jakarta.apache.org/commons/dbcp/

  • JDBC and Servlets

    I am writing a servlet which retrieves data from a database into a result set. I want to compare a username (taken into the servlet via a form for example) with a username from the result set.
    Can anyone tell me how this might be coded? Thanx.

    get the userid and password from the html form:
    String userid = req.getParameter("userid").trim();
    String password = req.getParameter("password").trim();
    find userid and password from database:
    String sql="SELECT PASSWORD FROM USER WHERE USERID =?";
    try{
    Class.forName(".............");
    con = DriverManager.getConnection(url,user,password);
    pstmt = con.prepareStatement(sql);
    pstmt.setString(1,userid);
    ResultSet result = pstmt.executeQuery();
    if(result != null){
    result.next();
    String pwd_DB = result.getString(1);
    Compare password:
    if (pwd_DB.equals(password)
    Hope it will give you some help.
    Yen

  • Implementing  jdbc using jsp and servlets

    please give me documnetation and few programs with code .
    implementing or using jdbc with servlets and jsp.

    please give me documnetation and few programs with
    code .
    implementing or using jdbc with servlets and jsp.Well, which do you want to do? Implement JDBC with servlets and JSP - a tricky job, but there's no technical reason why you couldn't for instance write a class which both extends HttpServlet and implements java.sql.Driver. Wouldn't recommend it, though

  • Servlet with Jdbc

    Hello,
    Can someone tells me how can I combine Jdbc and servlets.
    If someone has an example it's very nice.
    Thanks in advance
    kamel
    null

    I think i can help you.The example is :
    import java.io.* ;
    import java.sql.* ;
    import javax.sql.*;
    import oracle.jdbc.driver.*;
    public class test extends HttpServlet
    public void init(ServletConfig conf) throws ServletException
    super.init(conf);
    public void service(HttpServletRequest req, HttpServletResponse res)
    throws ServletException, IOException
    res.setContentType("text/html;charset=GB2312");
    ServletOutputStream out=res.getOutputStream();
    out.println("test");
    try
    Class.forName ("oracle.jdbc.driver.OracleDriver");
    Connection conn = DriverManager.getConnection
    ("jdbc:oracle:oci8:@oraserver", "ycjx", "xjcy");
    // ("jdbc:oracle:oci8:@qit-uq-cbiw_orcl", "scott", "tiger");
    // or oci7 @TNSNames_Entry, userid, password
    Statement stmt = conn.createStatement();
    ResultSet rset = stmt.executeQuery("select sj from dy_xstw");
    rset.next();
    out.println(rset.getString(1));
    rset.close();
    stmt.close();
    conn.close();
    catch (SQLException ex) {out.println("err1");}
    catch (ClassNotFoundException ex) { out.println("err2");}
    catch (java.lang.Exception ex) {out.println("err3"); }
    }

  • Servlet JDBC

    Can anyone please help me with pointing to the right direction on webapplications.
    I have a table in the database that returns 50K rows when running a query. I have been reading through some books and forums, SDN including that a correct way to access the database is through the Business tier EJB session beans and JPA and access these objects from Servlets. I understand that and I have an example that works using paging so I do not need to send all 50K records at once. My question is, the resultset retrieves entity objects and I have to create data transfer objects for each one of them to send to the GWT client? Doesn't it mean I have twice as much objects in the memory at a time to compare with accessing database through JDBC from Servlets directly? In the later case I wouldn't have any entity objects and occupy less memory? Is it completely wrong idea?
    Thanks

    mambo_jumbo wrote:
    Without their superpowers some of them are still not serializable for GWT.
    Never mind,
    Thanks for answer.I don't understand what the problem is here.
    Dod you have a problem with making them Serializable? They have to be Serializable if you want to make them arguments to remote methods anyway.

  • HELP! How te retrieve the last row in MYSQL database using Servlet!

    Hi ,
    I am new servlets. I am trying to retireve the last row id inserted using the servlet.
    Could someone show me a working sample code on how to retrieve the last record inserted?
    Thanks
    MY CODE
    import java.awt.*;
    import java.awt.event.*;
    import java.net.*;
    import java.io.*;
    import java.util.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.sql.*;
    public class demo_gr extends HttpServlet {
    //***** Servlet access to data base
    public void doPost (HttpServletRequest req, HttpServletResponse resp)
         throws ServletException, IOException
         String url = "jdbc:mysql://sql2.njit.edu/ki3_proj";
              String param1 = req.getParameter("param1");
              PrintWriter out = resp.getWriter();
              resp.setContentType("text/html");
              String semail, sfname, slname, rfname, rlname, remail, message;
              int cardType;
              sfname = req.getParameter("sfname");
              slname = req.getParameter("slname");
              rfname = req.getParameter("rfname");
              rlname = req.getParameter("rlname");
              semail = req.getParameter("semail");
              remail = req.getParameter("remail");
              message = req.getParameter("message");
              //cardType = req.getParameter("cardType");
              cardType = Integer.parseInt(req.getParameter("cardType"));
              out.println(" param1 " + param1 + "\n");
         String query = "SELECT * FROM greeting_db "
    + "WHERE id =" + param1 + "";
              String query2 ="INSERT INTO greeting_db (sfname, slname ,semail , rfname , rlname , remail , message , cardType ,sentdate ,vieweddate) values('";
              query2 = query2 + sfname +"','"+ slname + "','"+ semail + "','"+ rfname + "','"+ rlname + "','"+ remail + "','"+ message + "','"+ cardType + "',NOW(),NOW())";
              //out.println(" query2 " + query2 + "\n");
              if (semail.equals("") || sfname.equals("") ||
              slname.equals("") || rfname.equals("") ||
              rlname.equals("") || remail.equals("") ||
              message.equals(""))
                        out.println("<h3> Please Click the back button and fill in <b>all</b> fields</h3>");
                        out.close();
                        return;
              String title = "Your Card Has Been Sent";
              out.println("<BODY>\n" +
    "<H1 ALIGN=CENTER>" + title + "</H1>\n" );
                   out.println("\n" +
    "\n" +
    " From  " + sfname + ", " + slname + "\n <br> To  "
                                            + rfname + ", " + rlname + "\n <br>Receiver Email  " + remail + "\n<br> Your Message "
                                            + message + "\n<br> <br> :");
                   if (cardType ==1)
                        out.println("<IMG SRC=/WEB-INF/images/bentley.jpg>");
                   else if(cardType ==2) {
                        out.println("<IMG SRC=/WEB-INF/images/Bugatti.jpg>");
                   else if(cardType ==3) {
                        out.println(" <IMG SRC=/WEB-INF/images/castle.jpg>");
    else if(cardType ==4) {
                        out.println(" <IMG SRC=/WEB-INF/images/motocross.jpg>");
    else if(cardType ==5) {
                        out.println(" <IMG SRC=/WEB-INF/images/Mustang.jpg>");
    else if(cardType ==6) {
                        out.println("<IMG SRC=/WEB-INF/images/Mustang.jpg>");
    out.println("</BODY></HTML>");
         try {
              Class.forName ("com.mysql.jdbc.Driver");
              Connection con = DriverManager.getConnection
              ( url, "*****", "******" );
    Statement stmt = con.createStatement ();
                   stmt.execute (query2);
                   //String query3 = "SELECT LAST_INSERT_ID()";
                   //ResultSet rs = stmt.executeQuery (query3);
                   //int questionID = rs.getInt(1);
                   System.out.println("Total rows:"+questionID);
    stmt.close();
    con.close();
    } // end try
    catch (SQLException ex) {
              //PrintWriter out = resp.getWriter();
         resp.setContentType("text/html");
              while (ex != null) { 
         out.println ("SQL Exception: " + ex.getMessage ());
         ex = ex.getNextException ();
    } // end while
    } // end catch SQLException
    catch (java.lang.Exception ex) {
         //PrintWriter out = resp.getWriter();
              resp.setContentType("text/html");     
              out.println ("Exception: " + ex.getMessage ());
    } // end doGet
    private void printResultSet ( HttpServletResponse resp, ResultSet rs )
    throws SQLException {
    try {
              PrintWriter out = resp.getWriter();
         out.println("<html>");
         out.println("<head><title>jbs jdbc/mysql servlet</title></head>");
         out.println("<body>");
         out.println("<center><font color=AA0000>");
         out.println("<table border='1'>");
         int numCols = rs.getMetaData().getColumnCount ();
    while ( rs.next() ) {
              out.println("<tr>");
         for (int i=1; i<=numCols; i++) {
    out.print("<td>" + rs.getString(i) + "</td>" );
    } // end for
    out.println("</tr>");
    } // end while
         out.println("</table>");
         out.println("</font></center>");
         out.println("</body>");
         out.println("</html>");
         out.close();
         } // end try
    catch ( IOException except) {
    } // end catch
    } // end returnHTML
    } // end jbsJDBCServlet

    I dont know what table names and fields you have but
    say you have a table called XYZ which has a primary
    key field called keyID.
    So in order to get the last row inserted, you could
    do something like
    Select *
    from XYZ
    where keyID = (Select MAX(keyID) from XYZ);
    Good Luckwhat gubloo said is correct ...But this is all in MS SQL Server I don't know the syntax and key words in MYSQL
    This works fine if the emp_id is incremental and of type integer
    Query:
    select      *
    from      employee e,  (select max(emp_id) as emp_id from employee) z
    where      e.emp_id = z.emp_id
    or
    select top 1 * from employee order by emp_id descUday

  • Data retrieval displayed on multiple pages - Servlets

    I am using mysql database, JDBC and Servlets.
    Could anyone tell me the best way to display the data retrieved from the database in multiple pages. For example I have 215 records and I want the data displayed in several pages with 10 rows per page.
    I want something similar to these forum pages where I can move forward, back, first and last through the database.
    Thanks in advance

    Hans Bergsten's JSP book from O'Reilly has an example that manages that trick with JSTL. You should buy a copy and download the JSTL implementation from Jakarta and try it out. - MOD

  • ___Secure JDBC and Servlets___

    Hey all! I have an applet that uses jdbc calls to an oracle database, and servlets calls to oracle's jserv servlet container. It has been requested to make these connections secure.
    Can someone please point me into the right direction on information/documentation on performing secure jdbc and servlet calls.
    Thanks!

     

  • Error connecting to oracle DB using SAS 8.1

    Hi,
    I am using SAS 8.1(2005 Q1) and the oracle server is 9.2.0.1. I am trying to run a sample application given in the app server (jdbc-simple) and it's not connecting to the database.
    I am using oracle thin driver.
    I have created the jdbc connection pool named jdbc-pool too. Is there anything else I shud do? I am able to ping to the database using this connection pool but not able to run the application and getting http status 500 error with the following message:
    java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key exception
    This is the server.log file:
    [#|2005-08-22T13:04:45.356+0530|SEVERE|sun-appserver-pe8.1_02|javax.enterprise.system.container.web|_ThreadID=11;|WEB0783: Error commiting response
    java.io.IOException: An existing connection was forcibly closed by the remote host
         at sun.nio.ch.SocketDispatcher.write0(Native Method)
         at sun.nio.ch.SocketDispatcher.write(SocketDispatcher.java:33)
         at sun.nio.ch.IOUtil.writeFromNativeBuffer(IOUtil.java:104)
         at sun.nio.ch.IOUtil.write(IOUtil.java:75)
         at sun.nio.ch.SocketChannelImpl.write(SocketChannelImpl.java:302)
         at java.nio.channels.Channels.write(Channels.java:60)
         at java.nio.channels.Channels.access$000(Channels.java:47)
         at java.nio.channels.Channels$1.write(Channels.java:134)
         at org.apache.coyote.http11.InternalOutputBuffer.commit(InternalOutputBuffer.java:602)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.action(ProcessorTask.java:749)
         at org.apache.coyote.Response.action(Response.java:188)
         at org.apache.coyote.Response.sendHeaders(Response.java:380)
         at org.apache.coyote.tomcat5.OutputBuffer.doFlush(OutputBuffer.java:357)
         at org.apache.coyote.tomcat5.OutputBuffer.close(OutputBuffer.java:318)
         at org.apache.coyote.tomcat5.CoyoteResponse.finishResponse(CoyoteResponse.java:496)
         at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:188)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:653)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:534)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.doTask(ProcessorTask.java:403)
         at com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:55)
    |#]
    [#|2005-08-22T13:05:34.432+0530|WARNING|sun-appserver-pe8.1_02|javax.enterprise.resource.resourceadapter|_ThreadID=12;|RAR6017 : Failed to get connection pool object via JNDI lookup : jdbc-pool|#]
    [#|2005-08-22T13:07:39.704+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.deployment|_ThreadID=13;|DPL5109: EJBC - START of EJBC for [jdbc-simple]|#]
    [#|2005-08-22T13:07:39.724+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.deployment|_ThreadID=13;|Processing beans ...|#]
    [#|2005-08-22T13:07:39.814+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.deployment|_ThreadID=13;|DPL5110: EJBC - END of EJBC for [jdbc-simple]|#]
    [#|2005-08-22T13:07:41.707+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.deployment|_ThreadID=13;|Total Deployment Time: 10042 msec, Total EJB Compiler Module Time: 110 msec, Portion spent EJB Compiling: 1%
    Breakdown of EJBC Module Time: Total Time for EJBC: 110 msec, CMP Generation: 0 msec (0%), Java Compilation: 0 msec (0%), RMI Compilation: 0 msec (0%), JAX-RPC Generation: 50 msec (45%),
    |#]
    [#|2005-08-22T13:07:42.568+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.deployment|_ThreadID=13;|deployed with moduleid = jdbc-simple|#]
    [#|2005-08-22T13:07:43.459+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.admin|_ThreadID=14;|ADM1041:Sent the event to instance:[ApplicationDeployEvent -- reference-added jdbc-simple]|#]
    [#|2005-08-22T13:07:43.669+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.admin|_ThreadID=14;|ADM1042:Status of dynamic reconfiguration event processing:[success]|#]
    [#|2005-08-22T13:07:43.759+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.admin|_ThreadID=14;|ADM1041:Sent the event to instance:[ApplicationDeployEvent -- deploy jdbc-simple]|#]
    [#|2005-08-22T13:07:44.159+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.container.ejb|_ThreadID=14;|Instantiated container for: ejbName: jdbc-simpleEJB; containerId: 73708094084546560|#]
    [#|2005-08-22T13:07:44.430+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.core.classloading|_ThreadID=14;|LDR5010: All ejb(s) of [jdbc-simple] loaded successfully!|#]
    [#|2005-08-22T13:07:44.440+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.container.web|_ThreadID=14;|WEB0100: Loading web module [jdbc-simple:jdbc-simple.war] in virtual server [server] at [/jdbc-simple]|#]
    [#|2005-08-22T13:07:45.982+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.tools.admin|_ThreadID=14;|ADM1042:Status of dynamic reconfiguration event processing:[success]|#]
    [#|2005-08-22T13:10:48.029+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    GreeterDBServlet is executing ...|#]
    [#|2005-08-22T13:10:48.029+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Retrieving JNDI initial context...|#]
    [#|2005-08-22T13:10:48.049+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Retrieved initial context successfully|#]
    [#|2005-08-22T13:10:48.049+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Looking up dbGreeter bean home interface...|#]
    [#|2005-08-22T13:10:48.049+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Looking up: java:comp/env/ejb/jdbc-simple|#]
    [#|2005-08-22T13:10:48.169+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Looked up the EJB successfully|#]
    [#|2005-08-22T13:10:48.179+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Creating the dbGreeter bean...|#]
    [#|2005-08-22T13:10:48.189+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Created EJB successfully  |#]
    [#|2005-08-22T13:10:48.189+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Getting the message from the dbGreeter bean ...|#]
    [#|2005-08-22T13:10:48.229+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@1cce278|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@2848b1|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@bc9c25|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@af5e3c|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@153e9cf|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@1b16bd|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@7210ec|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@b4fa48|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@19bcae1|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@1249338|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@3d787c|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@1b12c9b|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@e797db|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@a2e5cc|#]
    [#|2005-08-22T13:10:48.239+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@1a7a525|#]
    [#|2005-08-22T13:10:48.249+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@52732d|#]
    [#|2005-08-22T13:10:48.249+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@107939f|#]
    [#|2005-08-22T13:10:48.249+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@6cdb70|#]
    [#|2005-08-22T13:10:48.249+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@baa4a4|#]
    [#|2005-08-22T13:10:48.249+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=16;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@18f22f3|#]
    [#|2005-08-22T13:10:48.259+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    ejbCreate() on obj samples.jdbc.simple.ejb.GreeterDBBean@15ec870|#]
    [#|2005-08-22T13:10:48.269+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    GreeterDB EJB is determining message...|#]
    [#|2005-08-22T13:10:48.269+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Message determined successfully|#]
    [#|2005-08-22T13:10:48.269+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Got this message from greeter bean: afternoon|#]
    [#|2005-08-22T13:10:48.269+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Getting the name input to this servlet...|#]
    [#|2005-08-22T13:10:48.269+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Got name: gmfgmf|#]
    [#|2005-08-22T13:10:48.269+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Recording the greeting in the database...|#]
    [#|2005-08-22T13:10:48.279+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Getting datasource...|#]
    [#|2005-08-22T13:10:48.279+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Got datasource successfully|#]
    [#|2005-08-22T13:10:48.279+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Getting connection...|#]
    [#|2005-08-22T13:10:48.870+0530|WARNING|sun-appserver-pe8.1_02|javax.enterprise.resource.resourceadapter|_ThreadID=15;|RAR5038:Unexpected exception while creating resource|#]
    [#|2005-08-22T13:10:48.870+0530|WARNING|sun-appserver-pe8.1_02|javax.enterprise.resource.resourceadapter|_ThreadID=15;|RAR5117 : Failed to obtain/create connection. Reason : Connection could not be allocated because: ORA-01017: invalid username/password; logon denied
    |#]
    [#|2005-08-22T13:10:48.870+0530|WARNING|sun-appserver-pe8.1_02|javax.enterprise.resource.resourceadapter|_ThreadID=15;|RAR5114 : Error allocating connection : [Error in allocating a connection. Cause: Connection could not be allocated because: ORA-01017: invalid username/password; logon denied
    ]|#]
    [#|2005-08-22T13:10:48.870+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Could not interact with the database|#]
    [#|2005-08-22T13:10:48.880+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Exception: java.sql.SQLException: Error in allocating a connection. Cause: Connection could not be allocated because: ORA-01017: invalid username/password; logon denied
    |#]
    [#|2005-08-22T13:10:48.880+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Storing the message in request object for the JSP...|#]
    [#|2005-08-22T13:10:48.880+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Stored message successfully|#]
    [#|2005-08-22T13:10:48.880+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Dispatching JSP for output...|#]
    [#|2005-08-22T13:11:48.408+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    GreeterDBView JSP is executing...|#]
    [#|2005-08-22T13:11:48.408+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    GreeterDBView JSP is all done|#]
    [#|2005-08-22T13:11:48.418+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Dispatched JSP successfully|#]
    [#|2005-08-22T13:11:48.418+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    GreeterDBServlet is all done
    |#]
    [#|2005-08-22T13:11:53.283+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    GreeterDBServlet is executing ...|#]
    [#|2005-08-22T13:11:53.283+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Retrieving JNDI initial context|#]
    [#|2005-08-22T13:11:53.293+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Retrieved initial context successfully|#]
    [#|2005-08-22T13:11:53.293+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Getting datasource...|#]
    [#|2005-08-22T13:11:53.293+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Got datasource successfully|#]
    [#|2005-08-22T13:11:53.293+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    Getting connection|#]
    [#|2005-08-22T13:11:53.644+0530|WARNING|sun-appserver-pe8.1_02|javax.enterprise.resource.resourceadapter|_ThreadID=15;|RAR5038:Unexpected exception while creating resource|#]
    [#|2005-08-22T13:11:53.644+0530|WARNING|sun-appserver-pe8.1_02|javax.enterprise.resource.resourceadapter|_ThreadID=15;|RAR5117 : Failed to obtain/create connection. Reason : Connection could not be allocated because: ORA-01017: invalid username/password; logon denied
    |#]
    [#|2005-08-22T13:11:53.664+0530|WARNING|sun-appserver-pe8.1_02|javax.enterprise.resource.resourceadapter|_ThreadID=15;|RAR5114 : Error allocating connection : [Error in allocating a connection. Cause: Connection could not be allocated because: ORA-01017: invalid username/password; logon denied
    ]|#]
    [#|2005-08-22T13:11:53.664+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.system.stream.out|_ThreadID=15;|
    - Could not interact with the database|#]
    [#|2005-08-22T13:11:53.674+0530|SEVERE|sun-appserver-pe8.1_02|javax.enterprise.system.container.web|_ThreadID=15;|StandardWrapperValve[GreeterDBLogDisplayServlet]: Servlet.service() for servlet GreeterDBLogDisplayServlet threw exception
    java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key exception
         at java.util.ResourceBundle.getObject(ResourceBundle.java:326)
         at java.util.ResourceBundle.getString(ResourceBundle.java:286)
         at samples.jdbc.simple.servlet.GreeterDBLogDisplayServlet.doGet(Unknown Source)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:747)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:860)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:249)
         at java.security.AccessController.doPrivileged(Native Method)
         at javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
         at org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:282)
         at org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:257)
         at org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)
         at org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)
         at java.security.AccessController.doPrivileged(Native Method)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:263)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
         at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:225)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:173)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:161)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:132)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:933)
         at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:185)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:653)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:534)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.doTask(ProcessorTask.java:403)
         at com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:55)
    |#]
    [#|2005-08-22T13:14:00.758+0530|WARNING|sun-appserver-pe8.1_02|javax.enterprise.tools.launcher|_ThreadID=10;|LAUNCHER005:Spaces in your PATH have been detected. The PATH must be consistently formated (e.g. C:\Program Files\Java\jdk1.5.0\bin; ) or the Appserver may not be able to start and/or stop.  Mixed quoted spaces in your PATH can cause problems, so the launcher will remove all double quotes before invoking the process. The most reliable solution would be to remove all spaces from your path before starting the Appservers components.  |#]
    [#|2005-08-22T13:14:00.948+0530|INFO|sun-appserver-pe8.1_02|javax.enterprise.tools.launcher|_ThreadID=10;|
    D:/j2eesdk-1_4_02/jdk\bin\java
    -client
    -Xmx512m
    -XX:NewRatio=2
    -Dcom.sun.aas.defaultLogFile=D:/j2eesdk-1_4_02/domains/domain1/logs/server.log
    -Dcom.sun.aas.verboseMode=true
    -Djava.endorsed.dirs=D:/j2eesdk-1_4_02/lib/endorsed
    -Djava.security.policy=D:/j2eesdk-1_4_02/domains/domain1/config/server.policy
    -Djava.security.auth.login.config=D:/j2eesdk-1_4_02/domains/domain1/config/login.conf
    -Dsun.rmi.dgc.server.gcInterval=3600000
    -Dsun.rmi.dgc.client.gcInterval=3600000
    -Djavax.net.ssl.keyStore=D:/j2eesdk-1_4_02/domains/domain1/config/keystore.jks
    -Djavax.net.ssl.trustStore=D:/j2eesdk-1_4_02/domains/domain1/config/cacerts.jks
    -Djava.ext.dirs=D:/j2eesdk-1_4_02/jdk/jre/lib/ext;D:/j2eesdk-1_4_02/domains/domain1/lib/ext
    -Djdbc.drivers=com.pointbase.jdbc.jdbcUniversalDriver
    -Djavax.management.builder.initial=com.sun.enterprise.admin.server.core.jmx.AppServerMBeanServerBuilder
    -Dcom.sun.enterprise.config.config_environment_factory_class=com.sun.enterprise.config.serverbeans.AppserverConfigEnvironmentFactory
    -Dcom.sun.enterprise.taglibs=appserv-jstl.jar,jsf-impl.jar
    -Dcom.sun.enterprise.taglisteners=jsf-impl.jar
    -Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl
    -Dcom.sun.aas.configName=server-config
    -Dorg.xml.sax.parser=org.xml.sax.helpers.XMLReaderAdapter
    -Ddomain.name=
    -Djmx.invoke.getters=true
    -Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl
    -Dcom.sun.aas.promptForIdentity=true
    -Dorg.xml.sax.driver=com.sun.org.apache.xerces.internal.parsers.SAXParser
    -Dcom.sun.aas.instanceRoot=D:/j2eesdk-1_4_02/domains/domain1
    -Djavax.xml.transform.TransformerFactory=com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl
    -Dcom.sun.aas.domainName=
    -Djava.util.logging.manager=com.sun.enterprise.server.logging.ServerLogManager
    -Dproduct.name=Sun-Java-System/Application-Server
    -Dcom.sun.enterprise.overrideablejavaxpackages=javax.faces,javax.servlet.jsp.jstl,javax.xml.bind,javax.help
    -Dcom.sun.aas.configRoot=D:/j2eesdk-1_4_02/config
    -Djava.library.path=D:\j2eesdk-1_4_02\lib;D:\j2eesdk-1_4_02\lib;D:\j2eesdk-1_4_02\jdk\bin;.;C:\WINNT\system32;C:\WINNT;D:\j2eesdk-1_4_02\lib;D:\j2eesdk-1_4_02\bin;D:\j2eesdk-1_4_02\bin;D:\j2eesdk-1_4_02\bin;D:\oracle\ora81\lib;C:\j2sdk1.4.2_08\bin;D:\oracle\ora81\bin;C:\Program Files\Oracle\jre\1.1.7\bin;C:\Program Files\Oracle\jre\bin;c:\winnt;c:\winnt\system32;D:/j2eesdk-1_4_02/jdk/bin;D:/j2eesdk-1_4_02/lib;D:/j2eesdk-1_4_02/lib/locale;D:/JBuilder7/lib/bes;D:/j2eesdk-1_4_02/imq/lib/imqxm.jar;D:\j2eesdk-1_4_02\bin;D:/j2eesdk-1_4_02/bin
    -Dcom.sun.aas.instanceName=server
    -Dcom.sun.aas.processLauncher=SE
    -cp
    D:/j2eesdk-1_4_02/jdk/lib/tools.jar;D:/j2eesdk-1_4_02/lib/appserv-rt.jar;D:/j2eesdk-1_4_02/lib\activation.jar;D:/j2eesdk-1_4_02/lib\admin-cli.jar;D:/j2eesdk-1_4_02/lib\appserv-admin.jar;D:/j2eesdk-1_4_02/lib\appserv-cmp.jar;D:/j2eesdk-1_4_02/lib\appserv-ext.jar;D:/j2eesdk-1_4_02/lib\appserv-jstl.jar;D:/j2eesdk-1_4_02/lib\appserv-upgrade.jar;D:/j2eesdk-1_4_02/lib\commons-launcher.jar;D:/j2eesdk-1_4_02/lib\commons-logging.jar;D:/j2eesdk-1_4_02/lib\dom.jar;D:/j2eesdk-1_4_02/lib\j2ee-svc.jar;D:/j2eesdk-1_4_02/lib\j2ee.jar;D:/j2eesdk-1_4_02/lib\jax-qname.jar;D:/j2eesdk-1_4_02/lib\jaxr-api.jar;D:/j2eesdk-1_4_02/lib\jaxr-impl.jar;D:/j2eesdk-1_4_02/lib\jaxrpc-api.jar;D:/j2eesdk-1_4_02/lib\jaxrpc-impl.jar;D:/j2eesdk-1_4_02/lib\jmxremote.jar;D:/j2eesdk-1_4_02/lib\jmxremote_optional.jar;D:/j2eesdk-1_4_02/lib\jsf-api.jar;D:/j2eesdk-1_4_02/lib\jsf-impl.jar;D:/j2eesdk-1_4_02/lib\mail.jar;D:/j2eesdk-1_4_02/lib\relaxngDatatype.jar;D:/j2eesdk-1_4_02/lib\rmissl.jar;D:/j2eesdk-1_4_02/lib\saaj-api.jar;D:/j2eesdk-1_4_02/lib\saaj-impl.jar;D:/j2eesdk-1_4_02/lib\xalan.jar;D:/j2eesdk-1_4_02/lib\xercesImpl.jar;D:/j2eesdk-1_4_02/lib\xsdlib.jar;D:/j2eesdk-1_4_02/lib/install/applications/jmsra/imqjmsra.jar;D:/j2eesdk-1_4_02/imq/lib/jaxm-api.jar;D:/j2eesdk-1_4_02/imq/lib/fscontext.jar;D:/j2eesdk-1_4_02/lib/ant/lib/ant.jar;D:/j2eesdk-1_4_02/pointbase/lib/pbclient.jar;D:/j2eesdk-1_4_02/pointbase/lib/pbembedded.jar;${oracle.jdbc.lib.class.path}/ojdbc14.jar;${oracle.jdbc.lib.class.path}/ojdbc14_g.jar;${oracle.jdbc.lib.class.path}/ocrs12.zip
    com.sun.enterprise.server.PEMain
    stop
    verbose|#]Cud someone tell me why am I getting this error?
    Regards,
    shipf1

    Other solution:
    on refresh period, default value is 1 minute, force this value at 0 and your connection
    is ok.
    Eric
    Joseph Weinstein <[email protected]> wrote:
    Redo the pool definition, and set 'test connection on reserve'. Don't
    set 'test connections on release', and leave refresh minutes alone.
    add a test table. DUAL is perfect for that. Everything else seems
    fine.
    Joe
    Rafid wrote:
    I am getting this error when I try to make a connection to an Oracle817DB.
    I am using Oracles drviers (classes12.zip)
    <Nov 2, 2001 2:05:18 PM EST> <Error> <JDBC> <Cannot startup connectionpool
    "genPool" Test table must be specifed for genPool with 'test connectionon
    reserve' or 'test connection on release' or 'refresh minutes' set higher
    than 0.>
    <Nov 2, 2001 2:05:18 PM EST> <Info> <JDBC> <Creating TX Data Sourcenamed
    weblogic.jdbc.jts.genPool for pool genPool>
    <Nov 2, 2001 2:05:18 PM EST> <Info> <JDBC> <Checking existence of connection
    pool genPool requested by user system>
    <Nov 2, 2001 2:05:18 PM EST> <Error> <JDBC> <Error during Data Source
    creation: weblogic.common.ResourceException:
    DataSource(weblogic.jdbc.jts.genPool) can't be created with non-existent
    Pool (connection or multi) (genPool)>
    I have created a connction pool called genPool,
    set the URL :jdbc:oracle:thin:@genoracle:1521:GENORANY
    driver class name = oracle.jdbc.driver.OracleDriver
    Properties:
    user=name ** where name is user
    password=xx **where xx is password
    dll=ocijdbc8
    protocol=thin
    I created the Tx Data Sources with
    name = weblogic.jdbc.jts.genPool
    jndi = weblogic.jdbc.jts.genPool
    poolname = genPool
    Can anyone help me through this, it would be a great help
    Rafid Wahab

  • Importing content of XML file to table(s)

    I am looking for a way to import updates passed via XML file to a three tables.
    In IBM Domino it was facilitated while using DOMParser class.
    Does JDeveloper have a class or method for updating tables from XML file?

    To import a XML document to a dataabse table:
    1. Add <Oracle10g>/jdbc/lib/ojdbc14.jar, <Oracle10g>/jdbc/lib/servlet.jar, <XDK>/lib/xmlparserv2.jar, <XDK>/lib/xdb.jar and classes12dms.jar to Classpath.
    2. Create a table in Oracle database 10g, which includes columns for each of the element tags in the XML document.
    3. Create a connection with the database.
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    Connection conn =
    DriverManager.getConnection("jdbc:oracle:thin:@<host>:<port>:<SID>",
    "<user>","<password>");
    4. Create a OracleXMLSave class object.
    OracleXMLSave oracleXMLSave =new OracleXMLSave(conn, "<table>");
    “<table>” is the database table.
    5. Set the tag for the row enclosing element.
    oracleXMLSave.setRowTag("<row-tag>");
    Each <row-tag> tag in the example XML document corresponds to a database column.
    6. Import the XML document to database:
    oracleXMLSave.insertXML(oracleXMLSave.getURL("file://c:/input.xml"));
    7. If the XML document has attributes apply an XSLT to convert the attributes to elements.

  • Simple (stupid) question...

    Hello everyone! I have what I hope is a really dumb question... I'm trying to use JDBC through an applet and keep getting the following SQLException after trying to use the DriverManager.getConnection call:
    SQLState: 08001
    Message : No suitable driver
    Error # : 0In order for an applet to use JDBC, does some sort of driver have to be installed on the client? or is it most likely some sort of logic error in my code? I copied the same logic from a .java application I have written that successfully connects to and queries the database, so I afraid that it may be something to do with the client-side of the fence, but in all reality, I'm clueless! Any advice would be much appreciated.
    Thanks,
    Jim H.

    There are two ways of connecting to a database on the server side.
    1. Untrusted applets cannot touch the hard disk of a computer. Thus, your applet cannot use native or other local files (such as JDBC database drivers) on your hard drive. The first alternative solution is to create a digitally signed applet which may use locally installed JDBC drivers, able to connect directly to the database on the server side.
    2. Untrusted applets may only open a network connection to the server from which they were downloaded. Thus, you must place a database listener (either the database itself, or a middleware server) on the server node from which the applet was downloaded. The applet would open a socket connection to the middleware server, located on the same computer node as the webserver from which the applet was downloaded. The middleware server is used as a mediator, connecting to and extract data from the database.
    3.
    (there is always one...) is to avoid to have to open a socket connection on your webserver as this could be seen a security thread and then disabled by firewalls. Instead you could write a "JDBC-driver" servlet and therefore would use only http requests. XML would be the first choice for the data going back-and-forth between your applet and the servlet.
    Bye

Maybe you are looking for