How to setup Oracle JDBC to suppot Chinese

Hi, I'm using Solaris 2.6 and Oracle 8. Does anyone knows how to setup Solaris/Oracle client to support Chinese charset ? I have setup NLS_LANG to AMERICAN_AMERICA.ZHT16BIG5 and my database with ZHT16BIG5 but JDBC query still shows ????.
Many thanks

Try this:
oracle.jdbc.driver.OracleDriver
jdbc:oracle:thin:@localhost:1521:XE
user
password
15

Similar Messages

  • How to setup a trackpad to write chinese charcters ?

    How to setup a trackpad to write Chinese characters?

    Hooray!! I followed your instruction and it works!  Big thanks

  • How to update oracle jdbc driver to 11.1.0.7.0 JDBC Drivers

    HI,
    I got a jdbc exception *" java.lang.ArrayIndexOutOfBoundsException "*.
    I have known that it is a Oracle JDBC bug and Oracle BUG number is BUG-6396242.
    The problem is too many rows per database transaction and it is fixed at version 11.1.0.7 Oracle JDBC Drivers.
    Here is the 11.1.0.7 Oracle JDBC Driver Readme.
    http://www.oracle.com/technetwork/database/enterprise-edition/111070-readme-083278.html
    and the download
    http://www.oracle.com/technetwork/database/enterprise-edition/jdbc-111060-084321.html
    My question is :
    *1.How to update oracle jdbc drivers with those downloads ?*
    (ps. I have replaced ojdbc5_g.jar, ojdbc5.jar, ojdbc6_g.jar, ojdbc6_g.jar in $ORACLE/jdbc, but it did'nt work. )
    *2.My Oracle version is 11.1.0.6.0, will it be OK if only update the JDBC driver?*
    *3.Do I need to update the jdbc driver where my program runs on the client side ?*
    Thanks for answers~ :)

    Upgrade your database version to 11.1.0.7.
    Installation docs are included with all patches and upgrades.

  • How to setup oracle database to archivelog mode and auto delete ?

    Oracle 11g R2
    - How to setup database to archive log mode and have oracle only save 24 hours of archive logs
    and delete the rest. So at any given time I will have only 24 hours of archive log and not more.
    So only 1 day of archive logs.
    - Let me know the database parameters I need to setup to accomplish this.
    - I don't want to use the RMAN
    - I am not setting up the database to archive log mode for recovery purpose. I am setting up archive log mode
    so we can use the log miner tool to dig up achives to see log activity for any performance & tuning.
    Edited by: johnpau2013 on May 9, 2012 6:09 PM

    johnpau2013 wrote:
    Thanks everyone for there responses.
    I need to rephrase and explain everyone as what I wanted to do exactly. This might help everyone understand and suggest me.
    We have oracle database 11g r2. Its a test database. Nothing is critical. We use EXPDP utility to backup the entire database every night. Which is enough for us to recover incase something happens. Even if we loose some data. That's fine.
    We are testing our web application on this oracle test database for performance & tuning.
    One thing we have noticed is that the redo logs are switching very frequently. 50MB each log file and there are 5 logs. each log switches every 40 seconds. So we wanted to see what is getting written in this redo logs. We wanted to use the LOG MINER tool in OEM to read the logs. It needed our database to be setup in archive log mode. So the log miner can read the archive logs and show us the sql's within the archive logs.
    Now when we setup the archive log mode on our database. By default the archive logs destination was set to flash recovery area ( may be oracle default archive log location is flash recovery area folder).
    We have setup the db_recovery_file_dest_size to 100GB. Now within 2 days we have filled up the flash recovery area folder. Database was frozen. Then we realized that its because oracle couldn't write archive logs. Because it reached the 100GB. Then we physically deleted files in the flash recovery area folder. Thinking it would help us start the frozen oracle database. But it didn't . The we realized that we are doing something wrong. As Oracle does not know that at OS level we deleted the files. Then temporarily we changed the db_recovery_file_dest_size to 130GB and were able to start the oracle database. Later we turned OFF the archive log mode.
    Being a rookie DBA we would have not read something properly.
    Finally:
    We wanted to know how to always keep only 1 day of archive logs (only for our performance tuning ) and not more than that. All we need this 1 day of archive logs is to use the log miner to read them. Backup is NOT our priority here. Only be able to read the archive logs from LOG MINER is PRIORITY.
    Correct me if I am wrong.Okay, so its making much more sense now, thanks for explaining your requirement.
    Database won't honor anything that you would do over the o/s without telling it. Your deletion of the archive log from the o/s location is NOT updated in the control file of the database and that's why, even when you had deleted the entire 100GB , from the db perspective, the space was still marked as used. This is the same which would happen even if you would increase the space from 100gb to whatever size as well. To delete the space, you would need to update the database's control file and that you can do from RMAN using its two commands , crosscheck backup following with deleted expired backup . The first command would find that which database backup files are NOT on the o/s which are shown in the control file and would mark all of them as expired. The second command would simply delete those expired files. This would update the control file and you would have your 100gb or whatever space, given back to you.
    To keep the archive logs of just one day, set up that Retention Policy for RMAN to either number of copies using the Redundancy option(default and set to 1) or Recovery Window. I believe for you Redundancy would be a suitable choice but you can have a read and play around with it. Setting it up would mark the files as Obsoleted and finally, you can write a small RMAN script to delete those obsoleted files.
    Now, what I don't understand is that why you want to keep on generating the archive logs just for the log miner? If you would have generated them once and figure out the reason for extensive redo generation(did you try increasing the redo log file size, 50mb seems to be smallish) , I don't think that there is any reason to keep on generating the archive logs still .
    And last part, for your question asked about that whether we can use RMAN to put the db in the archive log and is it a backup tool, yes and yes.
    HTH
    Aman....

  • How to Include Oracle JDBC Driver

    Hi Experts,
    We have a requirement to access the database  through Java Code. We are using NWDS. But we are n't able to find a clue, how to add the driver to the project. This option was there in Eclipse, if I remember correctly.
    We are using NWDS for the first time. Could any one please give a clue, if we need to do the same in a different way.
    Regards,
    SS

    Hi Vijay,
    Thanks for the reply. But we need a stand alone program to run at the command prompt(of SAP server), and the sample code is as follows.
    package abc;
    import java.sql.Driver;
    import java.sql.DriverManager;
    import java.sql.Connection;
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.sql.Statement;
    * @author SahuS
    * To change the template for this generated type comment go to
    * Window>Preferences>Java>Code Generation>Code and Comments
    public class InsertData {
         public static void main(String[] args) throws SQLException {
              Statement mystat = null;
              Connection conn = null;
              try
                     // Step 1: Load the JDBC driver.
                     Class.forName("oracle.jdbc.driver.OracleDriver");
                     // Step 2: Establish the connection to the database.
                       conn = DriverManager.getConnection(
                                       "jdbc:oracle:thin:@SERVERNAME:1527:SXI",       // URL
                                        "SAPSXIDB",       // username
                                         "PASSWORD"        // password
                         mystat = conn.createStatement();
                        ResultSet rs = mystat.executeQuery("select * from sapsxidb.zemp_1;");
                        while (rs.next()) {
                        System.out.println(
                        rs.getInt(1) +      // first column
                        "\t" +              // the horizontal tab
                        rs.getString(2)     // second column
                        mystat.close();
                        conn.close();                           
                   catch (Exception e)
                     System.err.println("Got an exception! ");
                     System.err.println(e.getMessage());
                   finally{
    As, we could not get the option to import the Oracle JDBC Driver, we are getting exception
    Got an exception!
    oracle.jdbc.driver.OracleDriver
    So, any clue, how we can import the driver in NWDS and use it?
    Regards,
    SS

  • How to import oracle.jdbc.OracleConnection

    I'm sure this is something I'm supposed to know but it has been about a year since I have worked with JDeveloper and I have forgotten a few things.
    I am looking at some code that includes import oracle.jdbc.OracleConnection with a wavy red line that gives the message "import oracle.jdbc.OracleConnection not found."
    Where should I start to look for how to repair this?
    Thanks,
    Gregory

    In your project properties, in the libraries and classpath section, add the library "Oracle JDBC".

  • How to use Oracle jdbc driver fixedString property?

    Oracle pads values in char columns so if I insert "a" in a CHAR(2) column then I cannot get that record by comparing that column to "a", I should get it by comparing it to "a ". Right?
    To solve this problem the Oracle jdbc driver has the property fixedString but I cannot make it work. (look for fixedString here )
    I'm using ojdbc14.jar driver for Oracle 10gR2 and accessing an Oracle 10gR2 database.
    This is my code:
    try {
    Properties props = new Properties();
    props.put("user", "****");
    props.put("password", "****");
    props.put("fixedString", true);
    Class.forName("oracle.jdbc.driver.OracleDriver");
    String jdbcUrl = "jdbc:oracle:thin:@<host>:<port>:<sid>";
    Connection connection = DriverManager.getConnection(jdbcUrl, props);
    PreparedStatement ps = connection.prepareStatement(
    "SELECT * FROM MY_TABLE WHERE MY_TABLE_ID = ?");
    ps.setObject(1, "abc"); // (*)
    // MY_TABLE_ID is CHAR(15)
    ResultSet rs = ps.executeQuery();
    while (rs.next())
    System.out.print("data: ");
    System.out.println(rs.getString("MY_TABLE_ID"));
    rs.close();
    ps.close();
    connection.close();
    } catch (SQLException ex) {
    ex.printStackTrace();
    } catch (ClassNotFoundException ex) {
    ex.printStackTrace();
    The above code executes fine (no exceptions thrown) but the ResultSet is empty after executeQuery().
    If I change the line (*) for
    ps.setObject(1, "abc ");
    Then I get the column I wanted. So it seems the driver is ignoring the fixedString option.
    I've also tried changing the line (*) for
    ps.setObject(1, "abc", java.sql.Types.CHAR);
    But the ResultSet I get is empty again. What am I missing?
    Thanks in advance

    Es un Bug se corrige en la versión del OAS 10.1.2.3
    Bug 10222534: UNABLE TO SET FIXEDSTRING PROPERTY IN DATASOURCE

  • How to use Oracle jdbc driver fixedString property in datasource.xml?

    I try configured fixedString property in the datasource.xml but doesnt work, this is in oc4j
    <data-source location="jdbc/prueba" class="com.evermind.sql.DriverManagerDataSource"
    password="xxxxx"
    max-connect-attempts="3"
    xa-location="jdbc/xa/prueba"
    ejb-location="jdbc/prueba"
    wait-timeout="1800"
    connection-driver="oracle.jdbc.driver.OracleDriver"
    username="xxxx" min-connections="35"
    max-connections="300"
    url="jdbc:oracle:thin:@144.1.0.54:1521:nodox"
    inactivity-timeout="300" name="jdbc/prueba">
    <property name="fixedString" value="true"/>
    </data-source>
    i Solved this problem in tomcat:
    <Resource name="jdbc/testsql" auth="Container"
    type="javax.sql.DataSource" driverClassName="oracle.jdbc.driver.OracleDriver"
    url="jdbc:oracle:thin:@144.1.0.54:1521:nodox"
    username="xxxxx" password="xxxxxxxx"
    maxActive="8" maxIdle="4" connectionProperties="fixedString=true;"/>

    Es un Bug se corrige en la versión del OAS 10.1.2.3
    Bug 10222534: UNABLE TO SET FIXEDSTRING PROPERTY IN DATASOURCE

  • How to avoid oracle.jdbc.driver.OracleConnection using

    i'am new in Java but recently i've got a project on support.
    Problem:
    solution worked on jvm 1.4, now on 1.7.
    Respectively, class oracle.jdbc.driver.OracleConnection has been used.
    Now I need class oracle.jdbc.OracleConnection to use CLOB.createTemporary() but...I can't.
    According to the docs, it's enough to replace in code and config files one class declaration on another. But NO. I replaced all of them in all config files and anyway, there was only oracle.jdbc.driver.OracleConnection has been created. (there is no explicit declaration of connection type in code, everything is configured in config files)
    Project uses marven, mybatis-3.1.1. Database: oracle 9
    Driver: ojdbc14-9.2.0.5.jar contains both classes: both oracle.jdbc.driver.OracleConnection (for backward compatibility) and oracle.jdbc.OracleConnection.
    The matter is what should i do to use second one instead of first one.
    May be there is some java cache? I do not know...
    Anybody knows?

    Now I need class oracle.jdbc.OracleConnection to use CLOB.createTemporary() but...I can't.
    Why not? You have to explain, in detail, WHAT you are trying and WHY you say you "can't" do it.
    According to the docs, it's enough to replace in code and config files one class declaration on another.
    That is correct - this IS all that is required. Replace ALL references to 'oracle.jdbc.driver' in your code.
    But NO. I replaced all of them in all config files and anyway, there was only oracle.jdbc.driver.OracleConnection has been created. (there is no explicit declaration of connection type in code, everything is configured in config files)
    We can't SEE what 'config' information you say you changed. It is what is in the CODE that matters, not what is in a config file.
    If the 'oracle.jdbc.driver' package is being imported by your code and a reference to 'Connection' is made Java will use it from the first package that it finds the class in.
    You are using an ANCIENT jdbc jar file. That doc you linked to WARNS you that you should upgrade and that doc is over ten years old.
    Remove that old jdbc jar file and use the current driver. Also remove references to the old package and replace them with references to the new package.
    With code and jars that are that old you can expect to have problems trying to use additional features, especially extensions. I would be surprised if you didn't have other issues as well.
    You need to perform code review to find all of the references that need to be corrected.

  • How to configure Oracle JDBC on iPlanet 6.0 ...

    Hello,
    On the Solaris machine I have iPlanet 6.0 sp2 and Oracle8i and I can't get my JSPs to connect to database. Everytime I try I get an error that the driver cannot be located. Even though I've udated a Classpath of iPlanet and Solaris to point to the oracle drivers. I spent already a day looking for some documenation on iPlanet and JDBC and I couldn't find anything except "run db_setup.sh". I don't have on my machine any db_setup.sh or setup_db.sh.
    Please let me know how configure iPlanet with Oracle drivers.
    Your help is greatly apprieciated,
    Leszek

    Typically, this is a simple matter of putting the zip file that contains the JDBC driver in the iPlanet server CLASSPATH. Make sure that you include the zip file name when you set the classpath, not just the directory that the zip is in: /opt/oracle/classes12_2.zip .
    You will need to restart iPlanet for this change to take effect.

  • How to setup Oracle 10g grid on a node other than SERVER

    Hi,
    We are in a process of moving the database residing on Windows servers to IBM AIX5L servers. For this purpose I came up with an idea of installing database on AIX and operate it remotely on Windows platform using 10g Grid Control and 10g Client. For this to happen perfectly, I am in middle of implementing same concept on Windows platfrom. I have made a test database on a Windows based server and I am trying to connect it with another Window based node. I know hwo to connect it using a client software but I am more interested to do it on Grid Control.
    At this stage, I have created database on server and have also configured Oracle Management Agent along with Oracle 10g Grid Control. I read oracle documentation that it is necessary to install Oracle Management Agent on server machine in order to let other nodes get connected with the server.
    I would extremely appreciate anyone who could help me in setting up 10g grid control on another node. Please note I wish to operate the database using grid control remotely. For know you can consider both computers on same network, I will go on VPN once I am able to do it on local network.
    Looking forward for your reply
    Shez

    Hi Xaheer,
    Thanks for looking into this matter. I had agent and grid running on the server and I have almost installed 10g Grid control 10.2.0.2. The place where I am stuck now is the OMS Configuration script that run after the installation in Configuration Assistant window. It just stuck here for some minutes and then displays the error. Let me paste here the lines in that appears in the detail panel of installation wizard.
    Output generated from configuration assistant "OMS Configuration"
    Command = oracle.sysman.emcp.oms.OmsPlugIn -configureOms
    Operation Stopping OPMN Processes is in progress.
    Operation EM Deploying is in progress.
    Operation Creating OMS Respository is in progress.
    Configuration assistant "OMS Configuration" failed
    The "d:\OracleHomes\agent10g\cfgtoollogs\configToolFailedCommands" script contains all commands that failed, were skipped or were cancelled. This file may be used to run these configuration assistants outside of OUI. Note that you may have to update this script with passwords (if any) before executing the same.-----------------------------------------------------------------------------
    According to the oracle installation guide, I had to deconfigure the database before running the setup. I did it using this command,
    emca -deconfig dbcontrol db -repos drop
    AS far as i think, I am getting this error becouse of sysman schema which was droped during the installation and was recreated( as I read in the oracle installation guide ) is not found by the script. So in order to b ring back sysman schema, I recreated the repository using following commands.
    emca -deconfig dbcontrol db -repos drop
    emca -config dbcontrol db -repos create
    Now, the database on server is not starting up. I can just see RED downword error, u know what i mean right ? Everyting is down, Database instance, Listener and Agent Connection to Instance, and on the top pf page I can see " Enterprise Manager is not able to connect to the database instance. The state of the components are listed below."
    When I try to startup the database using the grid control it gives me this error.
    Couldnot contact the agent. Verify that the url for the agent is null.
    I am stuck in here. If you know how to fix this agent , i would really appreciate that.
    Thanks

  • How to setup Oracle 11g OEM

    We use oracle 11g DB for Oracle Argus in win2008R2.
    It looks customer oracle 11g DB is not configured for OEM. I saw member login by SQLplus.
    Is there any step-by-step document to setup OEM of oracle DB in windows2008R2 ?

    This should be in the documentation, these are empty. For an example simply take a look in the OEM_EXEC_TEMPLATE.SQL file. You will see how this is done (basically empty ",")
    Jean-Pierre

  • How to setup Oracle OCI Driver with Kerberos Authentication in Eclipse

    Hello I am trying to setup a connection to Oracle Server with kerberos authentication.
    I am able to connect using SQL Developer but it seems impossible to do the same through the eclipse plugin any pointers?

    Currently there is no support for Kerberos authentication on OEPE DB support. I'll open an enhancement request.

  • How to get comparable Oracle JDBC performance using Java 1.4 vs 1.1.7?

    Our application makes extensive use of JDBC to access an Oracle database. We wrote it a number of years ago using java 1.1.7 and we have been unable to move to new versions of java because of the performance degradation.
    I traced the problem to JDBC calls. I can reproduce the problem using a simple program that simply connects to the database, executes a simple query and then reads the data. The same program running under java 1.4 is about 60% slower than under java 1.1.7. The query is about 80% slower and getting the data is about 150% slower!
    The program is attached below. Note, I run the steps twice as the first time the times are much larger which I attribute to java doing some initializations. So the second set of values I think are more representative of the actual performance in our application where there are numerous accesses to the database. Specifically, I focus on step 4 which is the execute query command and step 5 which is the data retrieval step. The table being read has 4 columns with 170 tuples in it.
    Here are the timings I get when I run this on a Sparc Ultra 5 running
    SunOs 5.8 using an Oracle database running 8.1.7:
                     java 1.1.7  java 1.4
            overall:    2.1s         3.5s
            step 1:     30           200
            step 2:    886          2009
            step 3:      2             2
            step 4:      9            17
            step 5:    122           187
            step 6:      1             1
            step 1:      0             0
            step 2:    203           161
            step 3:      0             1
            step 4:      8            15   <-   87% slower
            step 5:     48           117   <-  143% slower
            step 6:      1             2I find the same poor performance from java versions 1.2 and 1.3.
    I tried using DataDirect's type 4 JDBC driver which gives a little better performance but overall it is still much slower than using java 1.1.7.
    Why do the newer versions of java have such poor performance when using JDBC?
    What can be done so that we can have performance similar to java 1.1.7
    using java 1.4?
    ========================================================================
    import java.util.*;
    import java.io.*;
    import java.sql.*;
    public class test12 {
        public static void main(String args[]) {
            try {
                    long time1 = System.currentTimeMillis();
    /* step 1 */  DriverManager.registerDriver(
                        new oracle.jdbc.driver.OracleDriver());
                    long time2 = System.currentTimeMillis();
    /* step 2 */  Connection conn = DriverManager.getConnection (
                  "jdbc:oracle:thin:@dbserver1:1521:db1","user1","passwd1");
                    long time3 = System.currentTimeMillis();
    /* step 3 */  Statement stmt = conn.createStatement();
                    long time4 = System.currentTimeMillis();
    /* step 4 */  ResultSet rs = stmt.executeQuery("select * from table1");
                    long time5 = System.currentTimeMillis();
    /* step 5 */  while( rs.next() ) {
                      int message_num = rs.getInt(1);
                      String message = rs.getString(2);
                    long time6 = System.currentTimeMillis();
    /* step 6 */  rs.close(); stmt.close();
                    long time7 = System.currentTimeMillis();
                System.out.println("step 1: " + (time2 - time1) );
                System.out.println("step 2: " + (time3 - time2) );
                System.out.println("step 3: " + (time4 - time3) );
                System.out.println("step 4: " + (time5 - time4) );
                System.out.println("step 5: " + (time6 - time5) );
                System.out.println("step 6: " + (time7 - time6) );
                System.out.flush();
            } catch ( Exception e ) {
                System.out.println( "got exception: " + e.getMessage() );
            ... repeat the same 6 steps again...
    }

    If I run my sample program with the -server option, it
    takes a lot longer (6.8s vs 3.5s).Which has to be expected, as the -server option optimizes for long running programs - so it shoudl go with my second suggestion, more below...
    I am not certain what you mean by "just let the jvm
    running". Our users issue a command (in Unix) which
    invokes one of our java programs to access or update
    data in a database. I think what you are suggesting
    would require that I rewrite our application to have a
    java program always running on the users workstation
    and to also rewrite our
    commands (over a hundred) to some how pass data and
    receive data with this new server java program. That
    does not seem a very reasonable just to move to a new
    version of java. Or are you suggesting something
    else?No I was just suggestion what you descript. But if this is not an option, then maybe you should merge your java-programs to C or another native language. Or you could try the IBM-JDK with the -faststart (or similar) option. If thew Unix you mention is AIX, then there would be the option of a resetable-vm. But I cannot say if this VM would solve your problem. Java is definitly not good for applications which only issue some unqiue commands because the hotspot-compiler can not be efficiently used there. You can only try to get 1.1.7 performance by experimenting with vm-parameters (execute java -X).

  • How to Setup SSL on Oracle Application Server 10g Release 2 (10.1..2)

    Hi All,
    Can anybody tell me How to setup the SSL on Oracle Application Server 10g Release 2 (10.1.2).
    I have all the required documents like
    1. Oracle Application Server Portal Server Configuration Guide.
    2. Oracle Application Server Web Cache Configuration Guide.
    3. Oracle Application Server SSO Administration Guide.
    I tried to follow all this documents but still i am not able to set SSL for Oracle Portal Server.

    The Portal Configuration Guide, available on OTN at http://www.oracle.com/technology/documentation/appserver1012.html does provide some very specific information on how to set up OracleAS Portal.
    Section 6.3.2.1 Configuring SSL for OracleAS Portal describes various configurations, such as:
    SSL to OracleAS Single Sign-On
    SSL to OracleAS Web Cache
    SSL Throughout OracleAS Portal
    External SSL with Non-SSL Within Oracle Application Server
    For larger enterprise configurations, you can refer to the Enterprise Deployment Guide.
    Can you give a bit more background on what you are trying to set up? Which scenario, what sort of hardware, software versions, and so on.
    Regards,
    Pete

Maybe you are looking for

  • Sales order - automatic creation of purchase requisition - cost assignment

    Hi When the sales order is released, we have an automatic creation of Purchase requisation. We have given "internal order" as the cost obect in the sales order. But when the system has created automatic purchase requisition, it has not picked interna

  • How do I remove the black background when displaying photos in iphoto 8

    After upgrading to iphoto 8 my photos now sit on a black background when viewed from album, library or events. I have changed the slider from black to white in Preferences/Appearance but it only changes the display background for when the thumbnails

  • Kernel Panic In Mac OS 10.6.5

    Okay, I updated to Mac OS 10.6.5 yesterday and all seemed well. Today I had my somewhat usual Applications open (iChat, Mail, Safari, iTunes, Photoshop, Dashcode, and Final Cut Express Exporting) and when I went to save the Photoshop image it froze.

  • Facebook network in GraphML  format (using XSLT)

    hello, facebook developer platform provides a java api that allows us to extract friends list into java List of friends ids. my goal is to find a way to format facebook friends list data into GraphML format.this graphml file will be used to draw a Gr

  • Why doesn't reply arrow find my reply?

    When I click the curly arrow which should take me to the reply that I typed to an email, it tells me what it can't find the reply and that I may have deleted it. However, when I check in the Sent mail folder, there is my reply. Why can't Mail find it