Inserting broken pipe character in DB from Java creating problem

Hello experts,
We want to insert a broker pipe character in oracle 10g from java.
But it get changed to pipe character.
We are having japanese client for which we want to maintain this kind of character.
If someone know the solution, please update.

Hi,
I understand your explanation.
It is not possible to put actual code, that's complex and coupled with other things.
I like to share the scenario where it failing,
1. Broken Pipe character(double byte (\u00fa\u0055)) is put along with other japanese long text in a *.txt file.
2. A java file reads the above *.txt file and inserts the file text in a table column in oracle.
The .txt file is saved in Shift_JIS encoding.
In java file, the same *.txt file is read using 'CP943C' charset and written into database.
So as per your suggestion I have to compare literal first and than if I found broken bar in file, I need to change it with specified unicode.
Is that so?
--Saurabh.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

Similar Messages

  • How can I Insert a BLOB into a Table from Java?

    I have a Java class that creates an xml file from data in a non-sql data source. After it successfully creates and saves the file it inserts a record into an Oracle table to log the fact that an xml file was created.
    Now the guy in the warehouse wants to get an email with the file attached. I have been looking into the apex_mail package, because we already have a procedure using htmldb_mail. However, that procedure is on our old server with HTMLDB 1.6 and it is not sending any attachments.
    I think I have most of the apex_mail worked out, but I'm stuck on the blob thing. This is what I have so far:
    * The Java program creates a String object called xmlDoc
    * After xmlDoc is fully constructed, the file is written to the (Linux) server. This is accomplished with the following:
    // writing the xmlDoc
    fileDest = "/home/ewh/XMLOUT/";
    fileName = "OrderEW_"\+orderNbr\+"_"\+ticketNbr\+".xml";
    FileWriter fstream = new FileWriter(fileDest+fileName);
    BufferedWriter out = new BufferedWriter(fstream);
    out.write(xmlDoc);
    out.close();
    * Next I insert a record into the log file with:
    // Add a record to the Oracle order_email table to let the mail process know that
    // a new xml file is ready to be e-mailed to operations.
    emailLogInsertQuery = " insert into ewh.order_email ( file_name, create_date ) ";
    emailLogInsertQuery += " values ('"\+fileName\+"', sysdate)";
    oraAction = oraStmt.executeUpdate( emailLogInsertQuery );
    All of this is working fine so far. Now, I have added a blob type field to the order_email table, but I have no idea what to stick in there so that I have everything that apex_mail.add_attachment needs.
    Here's a description of the order_email table:
    SQL> desc ewh.order_email;
    Name Type Nullable Default Comments
    FILE_NAME VARCHAR2(30) Y
    FILE_BLOB BLOB Y
    CREATE_DATE DATE Y
    SEND_DATE DATE Y
    Thanks ever so much,
    Gregory
    Edited by: Canis Polaris on Jun 10, 2009 2:10 PM - Added escapes as necessary to show the plus signs around Java variables.

    Hi,
    From within APEX one can enter blob data in database tables, view the data and also update the data. Also one can send a blob attachment in an email.
    May be you can follow a combination of the following OBEs to insert BLOB data and send BLOB data from APEX:
    http://www.oracle.com/technology/obe/apex/apex31nf/apex31blob.htm
    http://www.oracle.com/technology/obe/apex/apex31nf/apex31email.htm
    -Priyanka

  • Unix Named pipes from Java

    Hello,
    My problem is with a unix named pipe which I have to write to. To do it, I have to use a FileOutputStream. It works fine when some process is reading the named pipe. My problem is when there is no process reading the pipe, my Java app gets blocked in the open method of the FileOutputStream.
    What we want is to open the FileOutputStream without blocking, although there is no process reading the pipe.Is it possible from Java? Is there anything similar to the unix NON_BLOCK?
    Thank you in advance.
    RCG@

    Hi,
    I think, in UNIX you would get the same problem, at least if you are writing then.
    By NON_BLOCK you would not be blocked, but you would get an error each time you try to write. So in UNIX in most cases the blocking is quite adequate: you want to "listen", until someone "calls", and then continue.
    I assume you want to open the pipe first to see if you can access it successfully.
    For this, try the same trick like with C in UNIX:
    Open that pipe first for reading. So there is a reading process: your JVM.
    Does this help you?
    Regards,
    Hartmut

  • Infamous SocketException: Broken Pipe

    Hello,
    As with many of the other users on this forum I have been plagued by the Broken Pipe SocketException, very rarely, which seems to essentially block on the java.net.SocketOutputStream.socketWrite0(Native Method) for quite a long time (presumably the length of some timeout) during a flush. It is also typically accompanied by a "java.net.SocketException: Connection timed out" on the socket itself.
    I've read the many responses by EJP that this means:
    "This is caused by writing to a connection when the other end has already closed it.
    So you have a poorly defined or implemented application protocol."
    My main question is: Is it normal for these exceptions to occur, and we just need to write some layer that handles this?
    And a follow up: If so, would that layer be something along the lines of:
    - a separate thread on the server for each output stream, and if this thread blocks during flush (for whatever reason), either:
    - use a watchdog thread to close the output if some internal timeout has exceeded, or:
    - just let Java's connection timeout eventually occur and let the output thread die
    Or am I way off base here?
    One more thing: Any other advice / best architectural practices / help regarding this problem / reading suggestions would be extremely appreciated.
    Thanks.

    EJP wrote:
    Or else you are just streaming large amounts of data and the peer giving up is part oft the application protocol(for example, the peer is a browser and the user navigates away), in which case th correct action is to catch the exception and give up on the client.I believe this might be the case. The clients can (and typically do) receive the information I am sending. It is absolutely possible that they can navigate away during the transfer. It is fine for the purposes of the application to give up on this client. To give up on the client and not have flush() block my main thread, I would need a separate thread per client, for handling the outputstream, correct? ie. one for receive, another for send, per client.
    There is something seriously wrong with your statement that the peer gets a connection timeout when this side gets a broken pipe. Connection timeout happens when creating a connection: in fact it happens instead of creating a connection. So there is no connection yet, so no peer at all, so it is impossible for the other end to be writing to the connection at all, because there is no connection and no other end. Do you mean a read timeout?I get:
    ThreadID-1310 java.net.SocketException: Connection timed out
    ThreadID-1310 java.net.SocketException: Broken pipe
    On the server-side thread that holds the socket for this client. The Connection timed out happens from the Socket InputStream during a readByte(), Broken pipe happens from the Socket OutputStream during a flush().
    Init code:
    socket_ = serverSocket_.accept();
    in_ = new DataInputStream(new BufferedInputStream(socket_.getInputStream()));
    out_ = new DataOutputStream(new BufferedOutputStream(socket_.getOutputStream()));
    mainThread.add(this); // the output main thread with some synchronization
    start(); // the read thread belowReceive in the thread that throws Connection Timed out:
    run() {
      while(running) {
        try {
          byte index = in_.readByte();
        } catch (SocketException e) {
          System.err.println(getId() + ": " + e);
    }Send code in main thread that throws broken pipe:
        try {
          callingThread_.out_.flush()
        } catch (SocketException e) {
          System.err.println(callingThread_.getId() + ": " + e);
      }Both exceptions happen back to back. The Main thread keeps a back-pointer to the calling thread As you can see, both in_ and out_ are from the same socket on the original object. The user has absolutely been connected for a while before this occurs.
    Thanks again for the insight.

  • Inserting the "enter" character in a String

    Hi,
    I would like to insert a "enter" character in a String to create a new line.
    something like this
    String test = "teste" + char(10) + "teste";
    Thanks in advanced
    Ricardo

    Are you trying to do this in an email? You didn't mention that. If your email encoding doesn't support new lines (the most simple encoding doesn't) you can't send them. I don't know why you'd get those results though, unless you actually put "\\n\\r" in the Java program.
    Anyway, it's not "my solution" it's just a fact. '\n' is the newline character and '\r' is the carriage return character.

  • FCC for Broken pipe delimited file

    Hi Fellow SDNer's
    I have a broken pipe delimited flat file . I want to do file content conversion for the same .
    Can you please help me with the parameters
    I am on PO 7.4 dual stack
    Thanks
    Ninad Sane

    Hi Ninad
    It looks like the broken pipe character is outside the US-ASCII character set.
    ASCII Code - The extended ASCII table
    You can try using the ASCII character to see if it works or not:-
    Header.fieldSeparator = '0xA6'
    Check also the following thread that mentions the use of non US-ASCII character.
    Content conversion - endSeparator and fieldSeparator with unusual separators
    In particular, it mentions OSS note 1936206 - if you have the corrections in place, you can try using MessageTransformBean and specifying the encoding with the following additional parameter.
    xml.fieldSeparator.encoding=ISO-8859-1
    Rgds
    Eng Swee

  • Error while calling stored procedure from Java

    Hi Guys,
    How are you everybody? I hope everything is goin fine on your side. I have one issue in PL/SQL while calling below stored procedures from Java.
    Problem Description: We have a stored procedure PROCEDURE BULK_INSERTS (
    V_SESSION_ID_TAB IN T_SESSION_ID_TAB_TYPE,
    V_SERVICE_TYPE_TAB IN T_SERVICE_TYPE_TAB_TYPE,
    V_SERVICE_LOCATION_TAB IN T_SERVICE_LOCATION_TAB_TYPE,
    V_SERVICE_CALL_NAME_TAB IN T_SERVICE_CALL_NAME_TAB_TYPE,
    V_SERVICE_CALL_START_TIME_TAB IN T_SERVICE_CALL_ST_TAB_TYPE,
    V_SERVICE_CALL_END_TIME_TAB IN T_SERVICE_CALL_ET_TAB_TYPE,
    V_SERVICE_CALL_DURATION_TAB IN T_SERVICE_CALL_DUR_TAB_TYPE,
    V_STATUS_TAB IN T_STATUS_TAB_TYPE,
    V_NOTES_TAB IN T_NOTES_TAB_TYPE
    ) and we are getting ora errors while calling this stored procedure from java.
    All tab types are declared locally, at package level.
    Here is error which occur while calling this sp:
    {call BULK_PKG.BULK_INSERTS(?,?,?,?,?,?,?,?,?)}
    And the parameter types we are using are:
    SESSION_ID - NUM_TAB_TYPE
    SERVICE_TYPE - VAR_TAB_TYPE
    SERVICE_LOCATION - VAR_TAB_TYPE
    SERVICE_CALL_NAME - VAR_TAB_TYPE
    SERVICE_CALL_START_TIME - DATE_TIME_TAB_TYPE
    SERVICE_CALL_END_TIME - DATE_TIME_TAB_TYPE
    SERVICE_CALL_DURATION - NUM_TAB_TYPE
    STATUS - VAR_TAB_TYPE
    NOTES - VAR_TAB_TYPE
    And the Exception stack trace is:
    ERROR (com.att.retail.r2d2.persistence.dao.ExternalServiceCallDAO.saveExternalServiceCallInfo(ExternalServi
    ceCallDAO.java:143)@ExecuteThread: '252' for queue: 'weblogic.kernel.Default') {Error attempting to save collected ESC data}
    java.sql.SQLException: ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PLS-00306: wrong number or types of arguments in call to 'BULK_INSERTS'
    ORA-06550: line 1, column 7:
    PL/SQL: Statement ignored
    at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:70)
    at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:112)
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:173)
    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:455)
    at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:413)
    at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:1030)
    at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:191)
    at oracle.jdbc.driver.T4CCallableStatement.executeForRows(T4CCallableStatement.java:944)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1222)
    at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3381)
    at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:3482)
    at oracle.jdbc.driver.OracleCallableStatement.execute(OracleCallableStatement.java:3856)
    at oracle.jdbc.driver.OraclePreparedStatementWrapper.execute(OraclePreparedStatementWrapper.java:1373)
    at weblogic.jdbc.wrapper.PreparedStatement.execute(PreparedStatement.java:98)
    at com.att.retail.r2d2.persistence.dao.ExternalServiceCallDAO.doBulkInsert(ExternalServiceCallDAO.java:220)
    at com.att.retail.r2d2.persistence.dao.ExternalServiceCallDAO.saveExternalServiceCallInfo(ExternalServiceCallDAO.java:138)
    Please help my guys out of this. I will really appreciate all suggestions and advices.
    Thank you everybody.

    I am trying to pass parameter to test my procedure but it is giving this error : ORA-06531: Reference to uninitialized collection
    ORA-06512: at line 12
    Here is example for my test procedure:
    declare
    v_session_id_tab SESSION_ID_TAB_TYPE;
    v_service_type_tab SERVICE_TYPE_TAB_TYPE ;
    v_service_location_tab SERVICE_LOCATION_TAB_TYPE ;
    v_service_call_name_tab SERVICE_CALL_NAME_TAB_TYPE;
    v_service_call_start_time_tab SERVICE_CALL_ST_TAB_TYPE;
    v_service_call_end_time_tab SERVICE_CALL_ET_TAB_TYPE;
    v_service_call_duration_tab SERVICE_CALL_DUR_TAB_TYPE;
    v_status_tab STATUS_TAB_TYPE;
    v_notes_tab NOTES_TAB_TYPE;
    begin
    v_session_id_tab(1) := 1;
    v_service_type_tab(1) := 'db';
    v_service_location_tab(1) := 'local';
    v_service_call_name_tab(1) := 'Name of call';
    v_service_call_start_time_tab(1) := SYSDATE;
    v_service_call_end_time_tab(1) := SYSDATE;
    v_service_call_duration_tab(1) := 100;
    v_status_tab(1) := 'Z';
    v_notes_tab(1) := 'NOTES';
    BULK_INSERTS (v_session_id_tab,v_service_type_tab, v_service_location_tab,v_service_call_name_tab,v_service_call_start_time_tab,v_service_call_end_time_tab,
    v_service_call_duration_tab, v_status_tab, v_notes_tab);
    end;
    I declare all types at schema level.
    Please give your comments.
    Thank you

  • Inserting CLOBs 32k failed with error "Broken Pipe"

    Hi,
    We use WLS 8.1 SP2 and Oracle 8i and the oracle thin jdbc driver ojdbc14.jar shipped
    with WLS.
    Inserting a clob >32k an SQL exception is raised ("Broken Pipe") and the db connection
    is becoming stale. Then a restart of WLS is necessary.
    Perhaps the current driver doesn't work with 8i ??
    Any thoughts?
    Thanks in advance

    Thomas wrote:
    Joe Weinstein <[email protected]> wrote:
    Thomas wrote:
    Hi,
    We use WLS 8.1 SP2 and Oracle 8i and the oracle thin jdbc driver ojdbc14.jarshipped
    with WLS.
    Inserting a clob >32k an SQL exception is raised ("Broken Pipe") andthe db connection
    is becoming stale. Then a restart of WLS is necessary.
    Perhaps the current driver doesn't work with 8i ??
    Any thoughts?
    Thanks in advanceThe first thing to do is to try Oracle's latest version of the thin driver.
    Joe
    We switched to Oracle 9.2.0.4.0 and installed the latest thin driver ojdbc14.jar
    (for Oracle 9.2.0.3). But there is always the same problem.
    Ok. As a last step before contacting Oracle, would you run that code,
    changing it to get it's connection directly from the oracle driver?
    If the same problem occurs, we can file a TAR with Oracle.
    Joe
    This is the code:
    PreparedStatement ps = null;
    try {
    con.prepareStatement(DBConstants.CREATE_IMPORT_LOG_ERROR);
    ps.setLong(1, logId);
    ps.setLong(2, recNo);
    ps.setInt(3, errorType);
    if (rec == null) rec = "NULL RECORD";
    CharArrayReader cReader = new CharArrayReader(rec.toCharArray());
    ps.setCharacterStream(4, cReader, rec.length());
    ps.setInt(5, PDBConstants.IMPORT_LOG_ERROR_STATUS_OPEN);
    ps.setString(6, "A");
    ps.executeUpdate();
    Here is the stack trace:
    <Jul 15, 2004 3:30:25 PM MEST> <Info> <EJB> <BEA-010051> <EJB Exception occurred
    during invocation from home: [email protected]
    threw exception: javax.ejb.EJBException: nested exception is: java.sql.SQLException:
    No more data to read from socket
    javax.ejb.EJBException: nested exception is: java.sql.SQLException: No more data
    to read from socket
    java.sql.SQLException: No more data to read from socket
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
    at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
    at oracle.jdbc.dbaccess.DBError.check_error(DBError.java:1160)
    at oracle.jdbc.ttc7.MAREngine.unmarshalUB1(MAREngine.java:963)
    at oracle.jdbc.ttc7.MAREngine.unmarshalSB1(MAREngine.java:893)
    at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:375)
    at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1894)
    at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:1094)
    at oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2132)
    at oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:2015)
    at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2877)
    at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:608)
    at weblogic.jdbc.wrapper.PreparedStatement.executeUpdate(PreparedStatement.java:94)
    at com.bspartners.pdb.provider.ProviderDAO.logFailedRecord(ProviderDAO.java:254)
    at com.bspartners.pdb.provider.ProviderServiceBean.startImport(ProviderServiceBean.java:478)
    at com.bspartners.pdb.provider.ProviderService_ma1gog_EOImpl.startImport(ProviderService_ma1gog_EOImpl.java:46)
    at com.bspartners.pdb.provider.ProviderService_ma1gog_EOImpl_WLSkel.invoke(Unknown
    Source)
    at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:477)

  • SQLException from Broken Pipe.

    We're using NetDynamics, and conecting to Oracle 8.1.7. We've just moved our applications from one data center to another, and we find that after running a few hours two of our NetDynamics instances are getting SQLExecptions as follows;
    System Err: java.sql.SQLException caught. Vendor Err: null Io exception: Broken pipe
    I've worked with out networking people and DBA's. It doesn't seem that the firewall is getting in the way. Any suggestions ?

    My colleague had a similar problem though they were using Tomcat's connection pooling. The error was cause because a keep alive validation query was required to have active connections available in the pool. Your problem may be something similar.

  • Java.rmi.MarshalException:....Broken pipe (plz help)

    Hi,
    I tried to run one simple RMI application..
    I got the RMI Server running...
    But While running the client I got the following Exception...
    java.rmi.MarshalException: error marshalling arguments; nested exception is:
    java.net.SocketException: Broken pipe
    at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:129)
    at engine.ServerMain_Stub.addTask(Unknown Source)
    at client.ClientMain.initCompute(ClientMain.java:38)
    at client.ClientMain.main(ClientMain.java:17)
    Caused by: java.net.SocketException: Broken pipe
    at java.net.SocketOutputStream.socketWrite0(Native Method)
    at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92)
    at java.net.SocketOutputStream.write(SocketOutputStream.java:136)
    at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:66)
    at java.io.BufferedOutputStream.write(BufferedOutputStream.java:105)
    at java.io.ObjectOutputStream$BlockDataOutputStream.drain(ObjectOutputStream.java:1639)
    at java.io.ObjectOutputStream$BlockDataOutputStream.setBlockDataMode(ObjectOutputStream.java:1548)
    at java.io.ObjectOutputStream.writeNonProxyDesc(ObjectOutputStream.java:1146)
    at java.io.ObjectOutputStream.writeClassDesc(ObjectOutputStream.java:1100)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1241)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1052) at java.io.ObjectOutputStream.writeFatalException(ObjectOutputStream.java:1355)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:281)
    at sun.rmi.server.UnicastRef.marshalValue(UnicastRef.java:265)
    at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:124)
    ... 3 more
    I am not able to understand the problem...
    Plz help..
    Regerds
    Jijo Vincent

    Hi, I got same stack trace within RMIConnector.
    MBean Server (= RIM Server) has bean alive, but a MBean client may get following Exception.
    I'm guessing that a port on server side was closed, cause rmi object on server side was unbinded from the rmi registory by some trigger.
    But I don't know what was the trigger for this...
    Caused by: java.rmi.MarshalException: error marshalling arguments; nested exception is:
    java.net.SocketException: Broken pipe
    at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:138)
    at com.sun.jmx.remote.internal.PRef.invoke(Unknown Source)
    at javax.management.remote.rmi.RMIConnectionImpl_Stub.invoke(Unknown Source)
    at javax.management.remote.rmi.RMIConnector$RemoteMBeanServerConnection.invoke(RMIConnector.java:993)
    at javax.management.MBeanServerInvocationHandler.invoke(MBeanServerInvocationHandler.java:288)
    ... 7 more
    Caused by: java.net.SocketException: Broken pipe
    at java.net.SocketOutputStream.socketWrite0(Native Method)
    at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92)
    at java.net.SocketOutputStream.write(SocketOutputStream.java:136)
    at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:65)
    at java.io.BufferedOutputStream.write(BufferedOutputStream.java:109)
    at java.io.ObjectOutputStream$BlockDataOutputStream.drain(ObjectOutputStream.java:1847)
    at java.io.ObjectOutputStream$BlockDataOutputStream.writeByte(ObjectOutputStream.java:1885)
    at java.io.ObjectOutputStream.writeFatalException(ObjectOutputStream.java:1546)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:333)
    at sun.rmi.server.UnicastRef.marshalValue(UnicastRef.java:274)
    at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:133)
    ... 11 more
    java.runtime.name = Java(TM) SE Runtime Environment
    java.runtime.version = 1.6.0_24-b07
    java.specification.name = Java Platform API Specification
    java.specification.vendor = Sun Microsystems Inc.
    java.specification.version = 1.6
    os.arch = amd64
    os.name = Linux
    os.version = 2.6.18-194.el5

  • Performance Analyzer crashes with "java.io.IOException: Broken pipe"

    Hi,
    I profile a distributed application using collect and Performance Analyzer. Till now, the Performance Analyzer really worked out nicely (thanks for that tool).
    However, since a couple of days, I work on a modified sideline of the code which crashes Performance Analyzer reliably when selecting a specific function in the "Function" tab.
    Has anyone of you experienced a similar problem or can give advice on how to work around this problem?
    (BTW: There is a bug report on broken pipes when multiple writers access a pipe - http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4028322 - but I'm not sure if this is the case here)
    I get the following error message:
    Exception in thread "AWT-EventQueue-0" com.sun.forte.st.mpmt.IPC$AnIPCException: java.io.IOException: Broken pipe
    at com.sun.forte.st.mpmt.IPC.sendByte(IPC.java:410)
    at com.sun.forte.st.mpmt.IPC.send(IPC.java:559)
    at com.sun.forte.st.mpmt.SummaryDisp.getSummary(SummaryDisp.java:430)
    at com.sun.forte.st.mpmt.SummaryDisp.doCompute(SummaryDisp.java:156)
    at com.sun.forte.st.mpmt.AnWindow.updateSummary(AnWindow.java:1366)
    at com.sun.forte.st.mpmt.FuncListDisp.updateSummary(FuncListDisp.java:223)
    at com.sun.forte.st.mpmt.FuncListDisp.access$400(FuncListDisp.java:11)
    at com.sun.forte.st.mpmt.FuncListDisp$TableHandler.valueChanged(FuncListDisp.java:405)
    at com.sun.forte.st.mpmt.AnTable.fireAnEvent(AnTable.java:827)
    at com.sun.forte.st.mpmt.AnTable.access$2700(AnTable.java:20)
    at com.sun.forte.st.mpmt.AnTable$CellHandler.valueChanged(AnTable.java:869)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:167)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:147)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:194)
    at javax.swing.DefaultListSelectionModel.changeSelection(DefaultListSelectionModel.java:388)
    at javax.swing.DefaultListSelectionModel.changeSelection(DefaultListSelectionModel.java:398)
    at javax.swing.DefaultListSelectionModel.setSelectionInterval(DefaultListSelectionModel.java:442)
    at javax.swing.JTable.changeSelectionModel(JTable.java:2294)
    at javax.swing.JTable.changeSelection(JTable.java:2363)
    at javax.swing.plaf.basic.BasicTableUI$Actions.actionPerformed(BasicTableUI.java:532)
    at javax.swing.SwingUtilities.notifyAction(SwingUtilities.java:1636)
    at javax.swing.JComponent.processKeyBinding(JComponent.java:2844)
    at javax.swing.JTable.processKeyBinding(JTable.java:5196)
    at javax.swing.JComponent.processKeyBindings(JComponent.java:2890)
    at javax.swing.JComponent.processKeyEvent(JComponent.java:2807)
    at java.awt.Component.processEvent(Component.java:5815)
    at java.awt.Container.processEvent(Container.java:2058)
    at java.awt.Component.dispatchEventImpl(Component.java:4410)
    at java.awt.Container.dispatchEventImpl(Container.java:2116)
    at java.awt.Component.dispatchEvent(Component.java:4240)
    at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1848)
    at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:693)
    at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:958)
    at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:830)
    at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:657)
    at java.awt.Component.dispatchEventImpl(Component.java:4282)
    at java.awt.Container.dispatchEventImpl(Container.java:2116)
    at java.awt.Window.dispatchEventImpl(Window.java:2429)
    at java.awt.Component.dispatchEvent(Component.java:4240)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:121)
    Caused by: java.io.IOException: Broken pipe
    at java.io.FileOutputStream.writeBytes(Native Method)
    at java.io.FileOutputStream.write(FileOutputStream.java:260)
    at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:65)
    at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:123)
    at com.sun.forte.st.mpmt.IPC.sendByte(IPC.java:407)
    ... 45 more
    Exception in thread "AWT-EventQueue-0" com.sun.forte.st.mpmt.IPC$AnIPCException: java.io.IOException: Broken pipe
    at com.sun.forte.st.mpmt.IPC.sendByte(IPC.java:410)
    at com.sun.forte.st.mpmt.IPC.send(IPC.java:559)
    at com.sun.forte.st.mpmt.AnWindow.setSelObj(AnWindow.java:2315)
    at com.sun.forte.st.mpmt.FuncListDisp$TableHandler.valueChanged(FuncListDisp.java:404)
    at com.sun.forte.st.mpmt.AnTable.fireAnEvent(AnTable.java:827)
    at com.sun.forte.st.mpmt.AnTable.access$2700(AnTable.java:20)
    at com.sun.forte.st.mpmt.AnTable$CellHandler.valueChanged(AnTable.java:869)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:167)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:147)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:194)
    at javax.swing.DefaultListSelectionModel.changeSelection(DefaultListSelectionModel.java:388)
    at javax.swing.DefaultListSelectionModel.changeSelection(DefaultListSelectionModel.java:398)
    at javax.swing.DefaultListSelectionModel.setSelectionInterval(DefaultListSelectionModel.java:442)
    at javax.swing.JTable.changeSelectionModel(JTable.java:2294)
    at javax.swing.JTable.changeSelection(JTable.java:2363)
    at javax.swing.plaf.basic.BasicTableUI$Actions.actionPerformed(BasicTableUI.java:532)
    at javax.swing.SwingUtilities.notifyAction(SwingUtilities.java:1636)
    at javax.swing.JComponent.processKeyBinding(JComponent.java:2844)
    at javax.swing.JTable.processKeyBinding(JTable.java:5196)
    at javax.swing.JComponent.processKeyBindings(JComponent.java:2890)
    at javax.swing.JComponent.processKeyEvent(JComponent.java:2807)
    at java.awt.Component.processEvent(Component.java:5815)
    at java.awt.Container.processEvent(Container.java:2058)
    at java.awt.Component.dispatchEventImpl(Component.java:4410)
    at java.awt.Container.dispatchEventImpl(Container.java:2116)
    at java.awt.Component.dispatchEvent(Component.java:4240)
    at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1848)
    at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:693)
    at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:958)
    at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:830)
    at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:657)
    at java.awt.Component.dispatchEventImpl(Component.java:4282)
    at java.awt.Container.dispatchEventImpl(Container.java:2116)
    at java.awt.Window.dispatchEventImpl(Window.java:2429)
    at java.awt.Component.dispatchEvent(Component.java:4240)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:121)
    Caused by: java.io.IOException: Broken pipe
    at java.io.FileOutputStream.writeBytes(Native Method)
    at java.io.FileOutputStream.write(FileOutputStream.java:260)
    at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:65)
    at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:123)
    at com.sun.forte.st.mpmt.IPC.sendByte(IPC.java:407)
    ... 41 more
    Thanks for your ideas, Manfred

    Which version of the Analyzer are you using? What OS, and
    what compiler did you use? Which version of Java are you using?
    (I doubt that the problem is related to the bug you cited; only
    one thread reads the pipe, and the bug concerns thread-safety
    reading from a pipe.)
    The most likely explanation is that er_print, the backend
    server that does the work for the GUI crashed. Is there a core
    dump from er_print in the directory?
    I'd suggest that if you're not using Sun Studio 12, patch_01,
    you upgrade to that and see if it still reproduces the problem.
    If it still crashes, we'll need more information to pursue it.
    You can send me email at marty dot itzkowitz at sun dot com
    We will need the experiment, and the a.out and .o containing the
    problematic function, and, of course, specific instructions for
    how to reproduce the problem.
    Marty Itzkowitz, project lead, Analyzer

  • Insert data from java to oracle object created

    Hi
    How can i insert data from java to table test with column LIST_QRY_RES_DN_MEMBER_INFO as below after create object type
    CREATE OR REPLACE TYPE QRY_RES_SERVICE_VALUES AS OBJECT (
      PARAMETER_CODE            VARCHAR2(60),
      PARAMETER_VALUE           VARCHAR2(60)
    CREATE OR REPLACE TYPE LIST_QRY_RES_SERVICE_VALUES AS TABLE OF QRY_RES_SERVICE_VALUES;
    CREATE OR REPLACE TYPE QRY_RES_OPTIONS AS OBJECT (
      SERVICE_CODE            VARCHAR2(60),
      SERVICE_VALUE           LIST_QRY_RES_SERVICE_VALUES 
    CREATE OR REPLACE TYPE LIST_QRY_RES_OPTIONS AS TABLE OF QRY_RES_OPTIONS;
    CREATE OR REPLACE TYPE QRY_RES_MEMBER_INFO AS OBJECT (
      VARIABLE_CODE            VARCHAR2(60),
      VARIABLE_VALUE           VARCHAR2(120)
    CREATE OR REPLACE TYPE LIST_QRY_RES_MEMBER_INFO AS TABLE OF QRY_RES_MEMBER_INFO;
    CREATE OR REPLACE TYPE QRY_RES_DN_MEMBER_INFO AS OBJECT (
      DN                       VARCHAR2(60),
      MEMBER_INFO              LIST_QRY_RES_MEMBER_INFO,
      OPTIONS                  LIST_QRY_RES_OPTIONS
    CREATE OR REPLACE TYPE LIST_QRY_RES_DN_MEMBER_INFO AS TABLE OF QRY_RES_DN_MEMBER_INFO;
    CREATE TABLE test(
    DN_MEMBER_INFO          LIST_QRY_RES_DN_MEMBER_INFO,
    NESTED TABLE DN_MEMBER_INFO STORE AS LIST_QRY_RES_DN_MEMBER_TAB
        (NESTED TABLE MEMBER_INFO STORE AS MEMBER_INFO_TAB,
         NESTED TABLE OPTIONS STORE AS LIST_QRY_RES_OPTIONS_TAB
            (NESTED TABLE SERVICE_VALUE STORE AS SERVICE_VALUE_TAB));

    It appears you are trying to store java objects (types) in a database rather than raw data (string, int, date types) that the object contains. If so, I don't think that ever really caught on. Most programmers store the raw data, then pull it out and populate a class. The problem with storing the object is that new versions of classes come out and your old version is stored in the database. If you just store the data, you don't have to worry about what version is in the database. You can populate the new version of the class with the same data.
    Also, others can use sql to query your data and use it for their own use independent of what you intended it for. I think most people use the (browser) based utility that comes with the database to create the tables, normalize them, set up primary keys, set up foreign keys, etc rather then run an sql statement as you did above.

  • How to insert into mysql the creation time and modification time from java?

    first how?
    Second what is better from create the date from java or do it from mysql?
    thanks in advace
    Pedro

    One way is to use the GetDate function in mysql. This will set the date as you insert data. insert into table(date) values(getdate())
    Anytime you modifiy the table just call the function again and update its fields.
    Dont know which is beter to do. In java or on the database side.

  • ORA-00911: invalid character - Calling a function from Java..

    Hi to all.. I have an issue when calling an oracle function from Java..
    This is my Java code:
    final StringBuffer strSql = new StringBuffer();
    strSql.append("SELECT GET_TBL('II_2_1_6_5') AS TABLA FROM DUAL;");
    st = conexion.createStatement();
    rs = st.executeQuery(strSql.toString());
    and in the executeQuery a SQLException is throwed:
    java.sql.SQLException: ORA-00911: invalid character
    I paste the query in TOAD and it works.. :S
    anybody knows how can I solve this?

    Remove the Semicolon after Dual.
    strSql.append("SELECT GET_TBL('II_2_1_6_5') AS TABLA FROM DUAL");
    Sushant

  • Web Service Error: java.sql.SQLException: Io exception: Broken pipe

    Hi,
    I am using JDeveloper PL/SQL web service generator. After some time we start receiving the "java.sql.SQLException: Io exception: Broken pipe" exception when we invoke the web service. I've noticed that the error starts occuring once all the connections in the database have been closed.
    Here are the Data Source configurations I tried using:
    <data-source name="jdev-connection-SACS" class="com.evermind.sql.DriverManagerDataSource" location="jdbc/SACSCoreDS" xa-location="jdbc/xa/SACSXADS" ejb-location="jdbc/SACSDS" pooled-location="jdbc/MACSPooledDS" connection-driver="oracle.jdbc.driver.OracleDriver" username="xxx" password="xxxx" url="jdbc:oracle:thin:@test:1521:SACS" inactivity-timeout="30" connection-retry-interval="3" max-connections="5" min-connections="0" wait-timeout="20"/>
    AND I also tried:
    <data-source name="jdev-connection-SACS" class="com.evermind.sql.DriverManagerDataSource" location="jdbc/SACSCoreDS" xa-location="jdbc/xa/SACSXADS" ejb-location="jdbc/SACSDS" pooled-location="jdbc/SACSPooledDS" connection-driver="oracle.jdbc.driver.OracleDriver" username="xxxx" password="xxxx" url="jdbc:oracle:thin:@xxxx:1521:SACS" inactivity-timeout="30"/>
    That did not make any changes.
    I then changed ConnectionContext.KEEP_CONNECTION to ConnectionContext.CLOSE_CONNECTION in the <name>Base.sqlj:
    public void release() throws SQLException
    { if (__tx!=null && __onn!=null) __tx.close(ConnectionContext.CLOSE_CONNECTION);
    __onn = null; __tx = null;
    That did not help either. We are running these web services on the standalone OC4J and Oracle 8.1.7.2 database with the MTS installed on it.

    Hi,
    I don't use JDeveloper to develop stored procedure web services. However, I do use WebServicesAssembler.jar to generate stored procedure web services.
    I had the same problem as you did. After some research in this forum, I was informed that it's a bug in the web services generator itself. I was also informed that the newest version of WebServicesAssembler.jar is supposed to fix the problem.
    If you want, you can always write a batch job to restart the OC4J periodically. The command is
    dcmctl -ct oc4j -co home
    If I come across the posting containing the answer to your solution, I will forward it to you.
    Good luck
    Jack

Maybe you are looking for

  • Photo in directory does not show up in album

    Hi, I'm new to PhtoShop and have a problem I can't fix. I have copied a photo, using Explorer, into a directory from which an album has created. When I do a general search for the photo by name, it appears but when I open the album it is not displaye

  • WM Putaway (LM03 + Change Bin at confirmation)

    I’m trying to use standard radio frequency transaction for “<u>Putaway by TO</u>” (LM03 *) to change the destination bin for a single-step confirmation TO during confirmation, but I only get “<u>Selection not possible</u>” message. Is there any funct

  • My iPod camera feature no longer works

    When I click the camera feature all I get is a black screen.  Help!

  • Datagrid with a datadriven combox

    Hi, I would like to implement a datagrid with a datadriven combox. The database should store "only" values, but should show a different labeltext in the grid. When the users load this Grid the stores values should be uses to set the comboboxes. That

  • Poor dl speed 1-3 Meg / Even poorer customer servi...

    I took up BT Infinity a few months ago and at the start the service was reasonably fast however over the last weeks the download speeds have been dropping - speedtest.net showing anything from 1-3 MB DL. I have tried to get in touch with BT Care via