URGENT! Java and Oracle

I'm currently developing a Java application that connects to an oracle database and retrieves various information. The application connects fine to the database and I can SELECT information and all the other basic stuff.
The problem I have is this, I have to call on server side scripts, .SQL files, to generate reports. From there I will somehow(?!) get the information that is contained in these reports but to start with I love to know how I can call these files.
If I log into sqlplus I can run the file as normal:
SQL>@file_name.sql
The above runs the file and the report is generated OK.
But if I try to use Java code such as ResultSet rs = statement.executeQuery() the program spits the dummy and tells me that I have supplied an "invalid SQL statement".
Bearing in mind I can use statement.executeQuery() to successfully perform SELECT's, UPDATE's etc. I simply swap the select information for "@file_name.sql" to immitate what happens at the sqlplus command prompt to execute.
All a total failure! If anyone knows would they please please help?!
Thanks in advance,
Tony

Hi jschell,
Many thanks for your reply by the way. Not to appear
completely thick and stupid but I aint a master of
Java by any means, is it possible you could suggest
how I would "make a system call that runs SQL*plus
and executes the script". Is there anywhere in
particular I would look to attain the source code to
achieve this? I have spent evening after evening
trying to find source or a pointer on how to achieve
this, I am beginning to get very frustrated!
Well first you need to figure out where you are going to run this.
It is either going to run on the client machine or it is going to run on the server. Both solutions are unlikely.
Your other attempt, with Runtime.exec() will only work on the client machine.
The server solution that I suggested requires PL/SQL, not java, to run the command. It will only work on the server. As for the packages I suggest you dig into your references (I would start with the O'Reilly books "Oracle PL/SQL Programming" and "Advanced Oracle PL/SQL Programming").

Similar Messages

  • How to relate java and Oracle

    i have to tried to make programs using java and oracle. if i give the values in the 'insert' statement it is getting updated in the original table in oracle but how to take the values from the text fields of java and insert into the tables in oracle. do we have any methods to convert the values into sql type. pl reply.

    Here is a sample of a Java program that uses JDBC and a PreparedStatement. This particular program does a select, but you can also use this for inserts. I'm not 100% this is what you are looking for, but if it isn't just let me know. I'll help if I can.
    Joel
    For inserts, just replace this code:
    ResultSet rs = ps.executeQuery();
    while (rs.next()) {
      System.out.println(rs.getInt(rs.findColumn("CNT")));
    }with this code (and obviously change the Select string to an Insert String):
    int rowcnt = ps.executeUpdate();Here is the whole program:
    import java.sql.*;
    import java.util.*;
    import java.text.*;
    class dbtest {
        public static void main(String args[]) throws SQLException {
            try {
                String timeString = new String("2000-11-01 23:59:59");
                SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd H:m:s");
                java.util.Date date = format.parse(timeString);
                Timestamp timestamp = new Timestamp(date.getTime());
                DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
                Connection conn =
                    DriverManager.getConnection(
                        "jdbc:oracle:thin:@riker:1521:mydb",
                        "myusername",
                        "mypassword");
                String sql =
                    "SELECT COUNT(*) CNT FROM SERVICE_ALARM "
                        + "WHERE TRANS_STREAM_NODE_ID = ? "
                        + "AND SERVICE_ID = ? "
                        + "AND ALARM_ID = ? "
                        + "AND RAISED > TO_DATE(?,'YYYY-MM-DD HH24:MI:SS')";
                PreparedStatement ps = conn.prepareStatement(sql);
                ps.setString(1, "ROW1");
                ps.setInt(2, 1);
                ps.setString(3, "ROW1");
                String myDate =
                    timestamp.toString().substring(0, timestamp.toString().length() - 2);
                System.out.println("myDate=(" + myDate + ")");
                ps.setString(4, myDate);
                ResultSet rs = ps.executeQuery();
                while (rs.next()) {
                    System.out.println(rs.getInt(rs.findColumn("CNT")));
                rs.close();
                ps.close();
            } catch (Exception e) {
                System.out.println("Java Exception caught, error message=" + e.getMessage());
    }

  • Java and oracle in linux

    hello frnds...i have installed oracle 10g in ubuntu 11.04....now i want to make database connection between java and oracle...so how can i do it??i know the java code..but the main problem is database driver..how can i give the classpath for specific jdbc dirver...pls tell me the steps to set classpath for jdbc driver...
    thnx in advance..

    884540 wrote:
    hello frnds...i have installed oracle 10g in ubuntu 11.04....now i want to make database connection between java and oracle...so how can i do it??i know the java code..but the main problem is database driver..how can i give the classpath for specific jdbc dirver...pls tell me the steps to set classpath for jdbc driver...
    thnx in advance..You can mention the classpath using the javac and java options:
    javac -cp .;<path> <ClassName>.java
    and
    java -cp .;<path> <ClassName>
    Or refer the below link to avoid mentioning classpath everytime you run/ compile the program
    http://www.linuxquestions.org/questions/linux-software-2/j2sdk-install-174483/#post898715

  • Webdynpro java and oracle DB connection..

    Hi,
    I have a good knowledge of WD (web dynpro java) projects having ECC as backend as i have done lot of projects where ECC is backend and WD JAVA is front end.
    but in my new project i have wd java as front end but my backend is oracle DB. I want to know how to create/setup  connection betwen webdynpro java and oracle DB, how to proceed on this ? wat all settings I have to do in VA (visual admin) and all.
    please let me know how to proceed on this. Any document/tutorial on this will be very helpful..

    Hi Rahul,
    Create a DataSource to the oracle db in Visual Admin, give the datasource an alias name and connect to the db from WebDynpro by calling the alias name.
    These document might be useful:
    [http://help.sap.com/saphelp_nw70/helpdata/en/c0/3ad4d5cdc66447a188b582aad537d3/frameset.htm]
    [SAP Note 867176|https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=867176]
    [SAP Note 941594|https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=0000941594&nlang=E]
    Good luck!
    Regards,
    Aditya

  • Relation between java and oracle

    Hi,
    This is general information about java and oracle.
    I had worked in java last one year, but now switch to oracle i heared that nearly combination of each are implemented oops concept. But i know where it used in java, not in oracle.
    In oracle, where we are implemented inheritance, polymorhism and encapsulation.
    plz give some tips
    Regards venki

    does this mean you used to develop your applications on java and manuplate your data in Oracle over JDBC or Hibernate but then you started to develop PL/SQL applications for this need and use PL/SQL's OO features?
    With my experiences I may say if you are working on data intensive database applications learning how to use effectively SQL and PL/SQL is critical, this is Oracle's native language not something written to work for any database vendor. http://www.oracle.com/pls/db102/portal.portal_db?selected=5

  • Reports from Java and Oracle database

    Hi
    I need to generate couple of reports from my application, with Java as front end and oracle 11.2.0.3.0.  database . Reports are  having very simple select statements, using the criteria users enter from GUI. we don't need to execute a  direct select statement from Java, with the where clauses . I did some research and found out about Pipelined functions. I tested for a small set of records and it worked fine. Will this work for large data set? any drawbacks of using this method?  Any other methods for this requirement?
    Thanks in advance
    JP

    Pipeline table functions do not sound like the appropriate approach. It is designed to primarily deal with data transformations. Using it as a rendering engine for report writing? There are fundamental problems with such an approach.
    As Dave and Andre commented - the CORRECT means for PL/SQL to pass "data" to Java (or other client languages) is via reference cursors (pointers that the client can use for referencing SQL cursor programs on the server). And Java as a report writer does not really compare with the ease and flexibility that Oracle Apex (Application Express) provides as a reporting framework.

  • 3 tiers model with Java and Oracle.

    Hi everybody. I have a problem with my work. I want to design a simple program follow 3 tiers model with Java and database is Oracle. But I do not know how I can design them. Please help me. It will better if you give some source code for each layer.
    Thanks in advance.
    Ky Thanh.

    I'd suggest searching the net for tutorials. Pick out the things you don't know about and need to know (SQL? JDBC? Java? software design in general?) and google: tier architecture, sql tutorial, etc. Sun's Java & JDBC tutorials are at http://java.sun.com/learning/tutorial/index.html
    Source for each tier? Read the JDBC tutorial and you can write the database tier source yourself. Learn Swing/Servlets/whatever you use for the user interface and you can write the top tier. The middle tier is your business logic, which is dependent on your area of business, and you'll need to know about the business and just general programming. Then if the tiers need to be distributed (hopefully not), you'll need to learn EJB or something.
    I hope you haven't been given a task there you aren't ready to take on... Learning to swim by jumping into the river is a great way to learn in a school assignment, but you mention work, and learning that way at work sounds a bit risky to me.

  • What files to download for java and oracle?

    Hey
    I have read that i have to download and implement some drivers to get oracle to work in
    java, but which should i download and where?
    Im using Oracle Express 10 and java 1.6
    Thanks

    Here's the link to get just the drivers
    http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html
    You could also install the oracle client if you wish to use sql*plus, it has jdbc drivers in folder named jdbc. This is probably a good idea as sql*plus can prove whether your problem is java or oracle.
    Installation is simple, you put ojdbc14.jar in the classpath of your compiles and executions. If you are using an IDE, you follow what it provides in its documentation. For Java Studio Enterprise you add them from the "Runtime" window.

  • Java and Oracle Reports

    How to connect java with oracle report server... i m using a swing application.... I have seen api documentation but didnt get things. please help...

    user13323568 wrote:
    How to connect java with oracle report server... i m using a swing application.... I have seen api documentation but didnt get things. please help...How can anyone help you?
    You "don't get things", that is a problem you have to solve before you can be helped. Maybe you just need to spend more time on it or find better documentation; API documentation is only a reference, not a manual.

  • Connection of java and oracle 10g express edition

    hello!!!!!
    I'm new to databases as well as JDBC. I want to know how to connect to oracle 10g express edition with java to create a desktop application.
    Let me know step by step procedure if possible.....
    Also tell me which softwares or drivers other than oracle 10g and jdk1.6 will be required......
    Do i need to keep all the required softwares and drivers in the same folder???
    please give any other information which is required for the connection
    thank you!!!

    hello!!!!!
    I'm new to databases as well as JDBC. I want to know how to connect to oracle 10g express edition with java to create a desktop application.
    Let me know step by step procedure if possible.....
    Also tell me which softwares or drivers other than oracle 10g and jdk1.6 will be required......
    Do i need to keep all the required softwares and drivers in the same folder???
    please give any other information which is required for the connection
    thank you!!!

  • Communication between Java and Oracle

    Hello,
    I have replicated databases running 9iR2.
    Once insert/update/delete transaction is commited
    by replication(master site, backend server),
    notification needs to be sent to front end server
    (eg rowid and tran type update/delete/insert)
    Upon insert/delete/update java stored procedure needs
    to open a socket to frontend server and pass the
    message (rowid and tran type update/delete/insert)
    How can this be accomplished?
    I believe this can be accomplished using Java stored
    procedure. Can someone explain how?
    Thanks.
    Oracop

    If you go up to Search, and enter "JMS", you'll get loads of documentation. http://tahiti.oracle.com will also have plenty of documentation. http://java.sun.com will also have lots of documentation and sample code.
    Justin

  • Java and oracle connection

    Hello
    I have made tables in oracle and im tryin g 2 connect these tables to java where i have made forms. i havent downloaded any driver but i think when i installed Oracle 8.1.7 it has jdbc drivers too. now i dont know which driver it is, thin, internal, etc. im tryin to run a separate code which checks the connection. It keeps giving an error saying that the" specified driver does not exist". but i dont know wot to do coz i dont know which driver it is.
    here is the code , hope somebody can help me
    import java.sql.*;
    import java.util.*;
    public class MyConnection
         Connection con;
         MyConnection()
              try
    // ******************************Connected To Jdbc-Odbc Type - 1 Driver
                   Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    //               con = DriverManager.getConnection("Jdbc:Odbc:dsnname","userid","password");
                   con = DriverManager.getConnection("jdbc:odbc:Driver={SQL Server};Server=servername;Database=pubs","userid","password");
    // ******************************Connected To Ms-Access JDBC ODBC Driver .
                   Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                   con = DriverManager.getConnection("Jdbc:Odbc:dsnname","","");
    //               con = DriverManager.getConnection("jdbc:odbc:Driver={MicroSoft Access Driver (*.mdb)};DBQ=G:/admin.mdb","","");
    // ******************************Connected To Ms-Access Type-3 Driver.
         /*          Class.forName ("acs.jdbc.Driver");
                   String url = "jdbc:atinav:servername:5000:C:\\admin.mdb";
                   String username="Admin";
                   String password="";
                   Connection con = DriverManager.getConnection(url,username,password);
    // ******************************Connected To Microsoft SQL.
                   Class.forName("com.microsoft.jdbc.sqlserver.SQLServerDriver");
                   con = DriverManager.getConnection("jdbc:microsoft:sqlserver://servername:1433","userid","password");
    // ******************************Connected To Merant.
                   Class.forName("com.merant.datadirect.jdbc.sqlserver.SQLServerDriver");
                   con = DriverManager.getConnection("jdbc:merant:sqlserver://servername:1433;User=userid;Password=password");
    // ******************************Connected To Atinav SqlServer.
                   Class.forName ("net.avenir.jdbc2.Driver");
                   con= DriverManager.getConnection("jdbc: AvenirDriver://servername:1433/pubs","userid","password");
    // ******************************Connected To J-Turbo.
    /*               String server="servername";
                   String database="pubs";
                   String user="userid";
                   String password="password";
                   Class.forName("com.ashna.jturbo.driver.Driver");
                   con= DriverManager.getConnection("jdbc:JTurbo://"+server+"/"+database,user,password);
    /*// ******************************Connected To jk Jdbc Driver.
                   String url= "jdbc:jk:server@pubs:1433";
                   Properties prop = new Properties();
                   prop.put("user","userid");//Set the user name
                   prop.put("password","password");//Set the password
                   Class.forName ("com.jk.jdbc.Driver").newInstance();
                   con = DriverManager.getConnection (url, prop);*/
    // ******************************Connected To jNetDirect Type - 4 Driver
    /*               String sConnect = "jdbc:JSQLConnect://127.0.0.1/database=pubs&user=userid&password=password";
                   Class.forName ("com.jnetdirect.jsql.JSQLDriver").newInstance();     
                   Connection con= DriverManager.getConnection(sConnect);
    // ******************************Connected To AvenirDriver Type - 4 Driver
    //               String url= "jdbc: AvenirDriver: //servername:1433/pubs";
    //               java.util.Properties prop = new java.util.Properties ();
    //               prop.put("user","userid");
    //               prop.put("password","password");
    /*               Class.forName ("net.avenir.jdbc2.Driver");     
                   System.out.println(" Connected To AvenirDriver Type - 4 Driver");
                   con= DriverManager.getConnection("jdbc: AvenirDriver://servername:1433/pubs","userid","password");
    // ******************************Connected To iNet Sprinta2000 Type - 4 Driver
         /*          String url="jdbc:inetdae7:servername:1433";
                   String login="userid";
                   String password="password";
                   Class.forName("com.inet.tds.TdsDriver");
                   System.out.println(" Connected To iNet Sprinta2000 Type - 4 Driver");
                   con=DriverManager.getConnection(url,login,password);
    // ******************************Connected To iNet Opta2000 Type - 4 Driver
    /*               String url="jdbc:inetdae7:servername:1433";
                   String login="sagar";
                   String password="sagar";
                   Class.forName("com.inet.tds.TdsDriver").newInstance();
                   System.out.println(" Connected To iNet Opta2000 Type - 4 Driver");
                   con=DriverManager.getConnection(url,login,password);
                   DatabaseMetaData md = con.getMetaData();
                   System.out.println("Driver Name            " + md.getDriverName());
                   System.out.println("Driver Version         " + md.getDriverVersion());
                   System.out.println("Database URL is        " + md.getURL());
                   System.out.println("Database UserName is   " + md.getUserName());
                   System.out.println("Connection Name        " + md.getConnection());
                   System.out.println("Database Name          " + md.getDatabaseProductName());
                   System.out.println("Database Version       " + md.getDatabaseProductVersion());
                   System.out.println("Database ReadOnly Type " + md.isReadOnly());
                   System.out.println("MaxColumnNameLength    " + md.getMaxColumnNameLength());
                   System.out.println("MaxConnections         " + md.getMaxConnections());
                   System.out.println("");
              catch(ClassNotFoundException cnfe)
                   System.out.println(cnfe.getException());
                   System.out.println("The Specified Driver Does not Exist....");
              catch(SQLException sqle)
                   if(sqle.getErrorCode() == 0)
                        System.out.println("No Suitable Driver Found..");
                   else if(sqle.getErrorCode() == 1017)
                        System.out.println("Wrong UserName Or Password..");
                   else if(sqle.getErrorCode() == 1034)
                        System.out.println("Database not Started..");
                        System.out.println(sqle.getErrorCode());
                        System.out.println(sqle.getSQLState());
                        System.out.println(sqle);
         public static void main (String args[])
              new MyConnection();
    }

    hi
    i did this as u told,
    import java.sql.*;
    import java.util.*;
    public class MyConnection
         Connection con;
         MyConnection()
              try
                      Class.forName("oracle.jdbc.driver.OracleDriver");
                      con = DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:Orahome","scott","tiger");
    // ******************************Connected To Jdbc-Odbc Type - 1 Driver
                   Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    //               con = DriverManager.getConnection("Jdbc:Odbc:dsnname","userid","password");
                   con = DriverManager.getConnection("jdbc:odbc:Driver={SQL Server};Server=servername;Database=pubs","userid","password");
    // ******************************Connected To Ms-Access JDBC ODBC Driver .
                   Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                   con = DriverManager.getConnection("Jdbc:Odbc:dsnname","","");
    //               con = DriverManager.getConnection("jdbc:odbc:Driver={MicroSoft Access Driver (*.mdb)};DBQ=G:/admin.mdb","","");
    // ******************************Connected To Ms-Access Type-3 Driver.
         /*          Class.forName ("acs.jdbc.Driver");
                   String url = "jdbc:atinav:servername:5000:C:\\admin.mdb";
                   String username="Admin";
                   String password="";
                   Connection con = DriverManager.getConnection(url,username,password);
    // ******************************Connected To Microsoft SQL.
                   Class.forName("com.microsoft.jdbc.sqlserver.SQLServerDriver");
                   con = DriverManager.getConnection("jdbc:microsoft:sqlserver://servername:1433","userid","password");
    // ******************************Connected To Merant.
                   Class.forName("com.merant.datadirect.jdbc.sqlserver.SQLServerDriver");
                   con = DriverManager.getConnection("jdbc:merant:sqlserver://servername:1433;User=userid;Password=password");
    // ******************************Connected To Atinav SqlServer.
                   Class.forName ("net.avenir.jdbc2.Driver");
                   con= DriverManager.getConnection("jdbc: AvenirDriver://servername:1433/pubs","userid","password");
    // ******************************Connected To J-Turbo.
    /*               String server="servername";
                   String database="pubs";
                   String user="userid";
                   String password="password";
                   Class.forName("com.ashna.jturbo.driver.Driver");
                   con= DriverManager.getConnection("jdbc:JTurbo://"+server+"/"+database,user,password);
    /*// ******************************Connected To jk Jdbc Driver.
                   String url= "jdbc:jk:server@pubs:1433";
                   Properties prop = new Properties();
                   prop.put("user","userid");//Set the user name
                   prop.put("password","password");//Set the password
                   Class.forName ("com.jk.jdbc.Driver").newInstance();
                   con = DriverManager.getConnection (url, prop);*/
    // ******************************Connected To jNetDirect Type - 4 Driver
    /*               String sConnect = "jdbc:JSQLConnect://127.0.0.1/database=pubs&user=userid&password=password";
                   Class.forName ("com.jnetdirect.jsql.JSQLDriver").newInstance();
                   Connection con= DriverManager.getConnection(sConnect);
    // ******************************Connected To AvenirDriver Type - 4 Driver
    //               String url= "jdbc: AvenirDriver: //servername:1433/pubs";
    //               java.util.Properties prop = new java.util.Properties ();
    //               prop.put("user","userid");
    //               prop.put("password","password");
    /*               Class.forName ("net.avenir.jdbc2.Driver");
                   System.out.println(" Connected To AvenirDriver Type - 4 Driver");
                   con= DriverManager.getConnection("jdbc: AvenirDriver://servername:1433/pubs","userid","password");
    // ******************************Connected To iNet Sprinta2000 Type - 4 Driver
         /*          String url="jdbc:inetdae7:servername:1433";
                   String login="userid";
                   String password="password";
                   Class.forName("com.inet.tds.TdsDriver");
                   System.out.println(" Connected To iNet Sprinta2000 Type - 4 Driver");
                   con=DriverManager.getConnection(url,login,password);
    // ******************************Connected To iNet Opta2000 Type - 4 Driver
    /*               String url="jdbc:inetdae7:servername:1433";
                   String login="sagar";
                   String password="sagar";
                   Class.forName("com.inet.tds.TdsDriver").newInstance();
                   System.out.println(" Connected To iNet Opta2000 Type - 4 Driver");
                   con=DriverManager.getConnection(url,login,password);
                   DatabaseMetaData md = con.getMetaData();
                   System.out.println("Driver Name            " + md.getDriverName());
                   System.out.println("Driver Version         " + md.getDriverVersion());
                   System.out.println("Database URL is        " + md.getURL());
                   System.out.println("Database UserName is   " + md.getUserName());
                   System.out.println("Connection Name        " + md.getConnection());
                   System.out.println("Database Name          " + md.getDatabaseProductName());
                   System.out.println("Database Version       " + md.getDatabaseProductVersion());
                   System.out.println("Database ReadOnly Type " + md.isReadOnly());
                   System.out.println("MaxColumnNameLength    " + md.getMaxColumnNameLength());
                   System.out.println("MaxConnections         " + md.getMaxConnections());
                   System.out.println("");
              catch(ClassNotFoundException cnfe)
                   System.out.println(cnfe.getException());
                   System.out.println("The Specified Driver Does not Exist....");
              catch(SQLException sqle)
                   if(sqle.getErrorCode() == 0)
                        System.out.println("No Suitable Driver Found..");
                   else if(sqle.getErrorCode() == 1017)
                        System.out.println("Wrong UserName Or Password..");
                   else if(sqle.getErrorCode() == 1034)
                        System.out.println("Database not Started..");
                        System.out.println(sqle.getErrorCode());
                        System.out.println(sqle.getSQLState());
                        System.out.println(sqle);
         public static void main (String args[])
              new MyConnection();
    }i tried it but i still get the same error msg. tht the specified driver does not exist.
    i have in my classpath - CLASSPATH=.;[ORACLE_HOME]jdbc\lib\classes12.zip
    and in my variable ORACLE_HOME AND it s value - C:\oracle\ora81
    the error that i get is
    C:\Program Files\JBuilder\jdk1.4\bin\javaw -classpath "C:\Documents and Settings\Administrator\jbproject\classes;C:\Program Files\JBuilder\jdk1.4\demo\jfc\Java2D\Java2Demo.jar;C:\Program Files\JBuilder\jdk1.4\demo\plugin\jfc\Java2D\Java2Demo.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\charsets.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\ext\dnsns.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\ext\ldapsec.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\ext\localedata.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\ext\sunjce_provider.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\im\indicim.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\jaws.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\jce.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\jsse.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\rt.jar;C:\Program Files\JBuilder\jdk1.4\jre\lib\sunrsasign.jar;C:\Program Files\JBuilder\jdk1.4\lib\dt.jar;C:\Program Files\JBuilder\jdk1.4\lib\htmlconverter.jar;C:\Program Files\JBuilder\jdk1.4\lib\tools.jar" MyConnection
    null
    The Specified Driver Does not Exist....

  • Java and Oracle support for Solaris 10?

    Hi
    Does anybody know when Oracle plans to support Solaris 10?
    We plan to purchase a Opteron server and would like to use Oracle.
    We also plan to use Sun Java AppServer Platform Edition. Any idea when that will support Solaris 10?
    Am I correct in assuming that Solaris x86 will run fine on an Opteron system.
    thanks in advance

    Oracle support Solaris 10 x86 but I doubt it's native 64 bits. The App. server is supported just go to Sun's site. The short answer is that Oracle and the App. server should both work but not necessarily in 64 bit mode.
    As for the Opteron system, you should check the HCL.

  • WebDynpro java and Oracle Connection

    Hi,
    I'm trying to make a simple connection to an Oracle database within a custom webdynpro component. Using NWDS 7.0.08 and EP 7.0 SP 10.
    Here is a sample of the java code I use :
    Connection conn = null;
    Class.forName("oracle.jdbc.driver.OracleDriver");
    DriverManager.registerDriver(new oracle.jdbc.driver.OracleDriver());
    conn =DriverManager.getConnection ("jdbc:oracle:thin:@hostname:port:DATABASENAME","schema", "password");
    Statement stmt=conn.createStatement();
    ResultSet rs=stmt.executeQuery("select * from MYTABLE");
    But when I run this WebDynpro, the following error appears :
    "oracle.jdbc.driver.OracleDriver".
    I have also catched the exception stack but it doesn't seem meaningful. If you need it, I can provide it in another thread.
    So What should I do to connect to this oracle database ? Is it the right provider ?
    Thanks,
    Loïc LEVEUGLE

    Hi!,
      please try following code, this is working fine for me.
    String  serverName = "172.21.1.62";
    String portNumber = "1526";
    String sid = "vision";
    String url = "jdbc:oracle:thin:@" + serverName + ":" + portNumber + ":" + sid;
    String userName = "scott";
    String password = "tiger";
    Connection connection = null;
    try {
        // Load the JDBC driver
        String driverName = "oracle.jdbc.driver.OracleDriver";
        Class.forName(driverName);
        connection = DriverManager.getConnection(url, userName, password);
        Statement stmt =connection.createStatement();
        PreparedStatement pstmt = connection.prepareStatement("insert into club (Name,EmpID,Location,Extention,MailID,InstPlay) values(?,?,?,?,?,?)");
                   pstmt.clearParameters();
        pstmt.setString(1,Name);
        pstmt.setString(2,EmpID);
        pstmt.setString(3,Location);
        pstmt.setString(4,Extention);
        pstmt.setString(5,MailID);
        pstmt.setString(6,Instrument);
        pstmt.executeUpdate();
    } catch(Exception exc) {
         exc.printStackTrace();
    put classes12.jar in your class Path.
    regards,
    Mithileshwar Sahu

  • Java and oracle connectivity

    Hi
    I have the connectivity from my java servlet to oracle database for changing the password on a series of servers. If the user can not login to the server or for any other reason there is a problem , there are 2 messages that are shown, one the message that java displays and the second one is the message that the oracle driver displays. I want to get these 2 messages and put them into a file but the problem is that I dont have access to the message generated by oracle driver. I dont know how to access that message, can u halp me plz?

    huh!

Maybe you are looking for

  • Message to Creative Admin - Any word when the beta drivers become

    Why is it that it seems creatives driver cycle is every 3 - 0 months??One of the things I believe that EA/DICE has done a great job with the BF2 is keeping everyone updated with the status of the patches... Everyone knows that BF2 was ridden with bug

  • Tring to sync ipad but getting error message

    Im trying to sync my ipad to my computer to manage my itunes but I keep getting a message that reads error could not sycn, please help

  • EXEC SQL Error: ORA-01401: Inserted value too large for column

    Getting this SQL Error: ORA-01401: Inserted value too large for column..on an EXEC SQL Insert statement when writing to an external Oracle DB from SAP. On further analysis..it appears that this happens to the fields..when the string length matches th

  • Smart form otf to pdf

    what are procedure shld follow  to download a smartform into pdf. i am calling directly smartform from the generated function by passing final table .

  • Content is loading in english

    Hi team We have one user logging, the tabs are showing in chinese langauage but the content is showing in english, What setting should be done, that the content sholud be displayed in chinese language. Regards, Bhaskar.T