Java.util.EmptyStackException

Hi All,
I am trying to configure weblogic 6.1 with Iplanet Webserver 6.0. I have all the EJB's placed in weblogic and the client class,jsp's and servlets in the IWS. I am getting theHome page but when I enter the user name and password I am getting the following error.
GetData: 'weblogic.socket.GetData@4183d3 - fd: '2372', numBytes: '1249''
java.util.EmptyStackException
at weblogic.utils.collections.Stack.pop(Stack.java:82)
at weblogic.rjvm.InboundMsgAbbrev.getAbbrev(InboundMsgAbbrev.java:85)
at weblogic.rjvm.MsgAbbrevInputStream.readImmutable(MsgAbbrevInputStream.java:193)
at weblogic.rjvm.MsgAbbrevInputStream.readClassDescriptor(MsgAbbrevInputStream.jav
a:207)
at weblogic.common.internal.ChunkedObjectInputStream$NestedObjectInputStream.readC
lassDescriptor(ChunkedObjectInputStream.java:300)
at java.io.ObjectInputStream.inputClassDescriptor(ObjectInputStream.java:901)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:361)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:231)
at java.io.ObjectInputStream.inputObject(ObjectInputStream.java:1181)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:381)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:231)
at weblogic.common.internal.ChunkedObjectInputStream.readObject(ChunkedObjectInput
Stream.java:110)
at weblogic.common.internal.ChunkedObjectInputStream.readObject(ChunkedObjectInput
Stream.java:123)
at weblogic.rjvm.ConnectionManager.readPeerInfo(ConnectionManager.java:694)
at weblogic.rjvm.ConnectionManagerServer.handleIdentifyRequest(ConnectionManagerSe
rver.java:263)
at weblogic.rjvm.ConnectionManager.dispatch(ConnectionManager.java:628)
at weblogic.rjvm.t3.T3JVMConnection.dispatch(T3JVMConnection.java:454)
at weblogic.socket.NTSocketMuxer.processSockets(NTSocketMuxer.java:658)
at weblogic.socket.SocketReaderRequest.execute(SocketReaderRequest.java:24)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
Kindly any one help me to solve this problem.
Thanks and Regards,
Arunkumar.

I have no idea, I would have assumed that it would accept some trash coding. Correcting that particular example might provide some progress towards an answer.
If the answer is that you have to have clean HTML, I'd look into HTMLTidy (I think JTidy is its Java implementation).

Similar Messages

  • Java.util.EmptyStackException Mapping error

    Hi All,
    I am integrating SAP ECC 6.0 system with SAP SNC.
    For these i am using  standard content of SAP SNC
    I am getting following mapping error :
    TransformerConfigurationException occurred when loading XSLT InvoiceRequest_InvoicInvoic01_01.xsl; details: Could not load stylesheet.com.sap.engine.lib.xml.util.NestedException: Error parsing query. -> java.util.EmptyStackException
    Plz help me out
    Regards Milan

    hi,
    check the interaface mapping which is used in your flow
    inside integration repository - is it working over there?
    do you see the XSL file in the external archives in repository?
    Regards,
    Michal Krawczyk
    http://mypigenie.com XI/PI FAQ

  • No graphs in DB load test: java.util.EmptyStackException

    Hi,
    We're getting ERROR [ViewGraphAction] Error creating counter tree java.util.EmptyStackException in wls_oats when trying to "view Run Graphs".
    It does not show any tree, so it is impossible to select graphs.
    Anyhting we can do about this?
    Edited by: ao on 2011-jun-14 16:28

    may be because you r trying to re-use the border edge variable. Try having a new instance. If that doesn't work, then check for JVM settings on either boxes of WinXP and MAC.
    hope i make it ;-)
    kamesh

  • Error while deploying a web service whose return type is java.util.Date

    Hi
    I have written a simple web service which takes in a date input (java.util.Date) and returns the same date back to the client.
    public interface Ping extends Remote
    * A simple method that pings the server to test the webservice.
    * It sends a datetime to the server which returns the datetime.
    * @param pingDateRequest A datetime sent to the server
    * @returns The original datetime
    public Date ping(Date pingDateRequest) throws RemoteException;
    The generation of the Web service related files goes smoothly in JDeveloper 10g. The problem arises when I try to deploy this web service on the Oracle 10g (10.0.3) OC4J standalone. it gives me the following error on the OC4J console :
    E:\Oracle\oc4j1003\j2ee\home\application-deployments\Sachin-TradingEngineWS-WS\
    WebServices\com\sachin\tradeengine\ws\Ping_Tie.java:57: ping(java.util.Date) in com.sachin.tradeengine.ws.Ping cannot be applied to (java.util.Calendar) _result  = ((com.sachin.tradeengine.ws.Ping) getTarget()).ping
    (myPing_Type.getDate_1());
    ^
    1 error
    04/03/23 17:17:35 Notification ==> Application Deployer for Sachin-TradingEngineWS-WS FAILED: java.lang.InstantiationException: Error compiling :E:\Oracle\oc4j1003\j2ee\home\applications\Sachin-TradingEngineWS-WS\WebServices: Syntax error in source [ 2004-03-23T17:17:35.937GMT+05:30 ]
    I read somewhere that the conversion between java to xml datatype and vice versa fails for java.util.Date, so it is better to use java.util.Calendar. When I change the code to return a java.util.Calendar then the JDeveloper prompts me the following failure:
    Method Ping: the following parameter types do not have an XML Schema mapping and/or serializer specified : java.util.Calendar.
    This forces me to return a String data.
    I would appreciate if someone can help me out.
    Thanks
    Sachin Mathias
    Datamatics Ltd.

    Hi
    I got the web service working with some work around. But I am not sure it this approach would be right and good.
    I started altogether afresh. I did the following step :
    1. Created an Interface (Ping.java) for use in web Service as follows :
    public interface Ping extends Remote{
    public java.util.Date ping(java.util.Date pingDateRequest)
    throws RemoteException;
    2. Implemented the above interface in PingImpl.java as follows :
    public class PingImpl implements Ping
    public java.util.Date ping(java.util.Date pingDateRequest) throws RemoteException {
    System.out.println("PingImpl: ping() return datetime = " + pingDateRequest.toString());
    return pingDateRequest;
    3. Compiled the above 2 java files.
    4. Generated a Stateless Java Web Service with the help of JDeveloper. This time the generation was sucessful.(If I had "java.util.Calendar" in place of "java.util.Date" in the java code of the above mentioned files the web service generation would prompt me for error)
    5. After the generation of Web Service, I made modification to the Ping interface and its implementing class. In both the files I replaced "java.util.Date" with "java.util.Calendar". The modified java will look as follows :
    Ping.Java
    =========
    public interface Ping extends Remote{
    public java.util.Calendar ping(java.util.Calendar pingDateRequest)
    throws RemoteException;
    PingImpl.Java
    ================
    public class PingImpl implements Ping
    public java.util.Calendar ping(java.util.Calendar pingDateRequest) throws RemoteException {
    System.out.println("PingImpl: ping() return datetime = " + pingDateRequest.toString());
    return pingDateRequest;
    6. Now I recompile both the java files.
    7. Withour regenerating the Web Service I deploy the Web Service on OC4j 10.0.3 from JDeveloper. This time the deployment was sucessful.(The Deployment fails if I don't follow the step 5.)
    8. Now I generated a Stub from JDeveloper and accessed the stub from a client. It works fine. Here if you see the Stub code it takes java.util.Date as a parameter and returns a java.util.Date. (Mind you I am accepting a java.util.Calendar and returning the same in my Web Service interface. Step 5)
    The confusing thing is the Serialization and Deserialization of Data from Client java data to Soap message and Soap message to Server java data.
    From Client to SOAP :
    java.util.Date to datetime
    From SOAP to Server :
    datetime to java.util.Calendar
    From Server to SOAP :
    java.util.Calendar to datetime
    From SOAP to Client :
    datetime to java.util.Date (I am not able to understand this part of the conversion)
    Any help or inputs would be appreciated.
    Thanks
    Sachin Mathias

  • Error-java.util.ResourceBundle.throwMissingResourceException

    hi all,
    im implementing a report for reporting empty filder..
    i got an error while running the report in portal.
    i got this error..
    unexpected error accessing report com.sap.km.reporting.SimpleReport@641ffc: java.util.MissingResourceException: Can't find bundle for base name com.sap.km.reporting.SimpleReport, locale en_IE
                at java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:839)
                at java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:729)
                at java.util.ResourceBundle.getBundle(ResourceBundle.java:579)
                at com.sap.km.reporting.SimpleReport.getDisplayName(SimpleReport.java:68)
                at com.sapportals.wcm.repository.manager.reporting.monitor.ReportComponent$ReportWrapper.getDisplayName(ReportComponent.java:294)
                at com.sapportals.wcm.repository.manager.reporting.types.RPReportHandler$DisplayNameGen.getProperty(RPReportHandler.java:160)
                at com.sapportals.wcm.repository.manager.reporting.types.RPPropHandler.getProperties(RPPropHandler.java:110)
                at com.sapportals.wcm.repository.manager.reporting.types.RPPropHandler.getProperties(RPPropHandler.java:143)
                at com.sapportals.wcm.repository.manager.reporting.RPPropertyManager.getProperties(RPPropertyManager.java:89)
                at com.sapportals.wcm.repository.ResourceImpl.internalGetProperties(ResourceImpl.java:3699)
                at com.sapportals.wcm.repository.ResourceImpl.internalGetPropertiesExtended(ResourceImpl.java:1343)
                at com.sapportals.wcm.repository.ResourceImpl.getProperties(ResourceImpl.java:1308)
                at com.sapportals.wcm.repository.CollectionImpl.getChildren(CollectionImpl.java:383)
                at com.sapportals.wcm.service.resourcelistfilter.cm.ResourceListFilter.getChildren(ResourceListFilter.java:425)
                at com.sapportals.wcm.rendering.collection.cm.InternalTree.getChildren(InternalTree.java:1868)
                at com.sapportals.wcm.rendering.collection.cm.InternalTree.getFirstCallOpenResources(InternalTree.java:1142)
                at com.sapportals.wcm.rendering.collection.cm.InternalTree.getFirstCallOpenResources(InternalTree.java:1172)
                at com.sapportals.wcm.rendering.collection.cm.InternalTree.buildNewTree(InternalTree.java:704)
                at com.sapportals.wcm.rendering.collection.cm.InternalTree.renderTree(InternalTree.java:852)
                at com.sapportals.wcm.rendering.collection.cm.InternalTree.render(InternalTree.java:546)
                at com.sapportals.wcm.rendering.collection.cm.InternalTree.buildContent(InternalTree.java:2295)
                at com.sapportals.wcm.control.util.components.base.BaseCompositeComponent.buildComposition(BaseCompositeComponent.java:196)
                at com.sapportals.htmlb.AbstractCompositeComponent.preRender(AbstractCompositeComponent.java:33)
                at com.sapportals.htmlb.Container.preRender(Container.java:118)
                at com.sapportals.htmlb.Container.preRender(Container.java:118)
                at com.sapportals.htmlb.Container.preRender(Container.java:118)
                at com.sapportals.htmlb.Container.preRender(Container.java:118)
                at com.sapportals.htmlb.AbstractCompositeComponent.preRender(AbstractCompositeComponent.java:34)
                at com.sapportals.htmlb.Container.preRender(Container.java:118)
                at com.sapportals.htmlb.Container.preRender(Container.java:118)
                at com.sapportals.htmlb.Container.preRender(Container.java:118)
                at com.sapportals.portal.htmlb.PrtContext.render(PrtContext.java:413)
                at com.sapportals.htmlb.page.DynPage.doOutput(DynPage.java:237)
                at com.sapportals.wcm.portal.component.base.KMControllerDynPage.doOutput(KMControllerDynPage.java:130)
                at com.sapportals.htmlb.page.PageProcessor.handleRequest(PageProcessor.java:129)
                at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.java:134)
                at com.sapportals.wcm.portal.component.base.ControllerComponent.doContent(ControllerComponent.java:73)
                at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)
                at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)
                at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:328)
                at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:136)
                at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:189)
                at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:215)
                at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:646)
                at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:328)
                at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:136)
                at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:189)
                at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:753)
                at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:240)
                at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:522)
                at java.security.AccessController.doPrivileged(Native Method)
                at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:405)
                at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
                at com.sap.engine.services.servlets_jsp.server.servlet.InvokerServlet.service(InvokerServlet.java:156)
                at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
                at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:390)
                at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:264)
                at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:347)
                at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:325)
                at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:887)
                at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:241)
                at com.sap.engine.services.httpserver.server.Client.handle(Client.java:92)
                at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:148)
                at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
                at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
                at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
                at java.security.AccessController.doPrivileged(Native Method)
                at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:95)
                at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:160)
    could anyone provide me a solution for this..
    Regards,
    Vinoth

    See Error -Can't find bundle ,locale en_US

  • Unable to capture messages from java.util.logging

    I have a class called (Caller.java) which invokes a method called foo from another java class(Util.java) using reflection API.Now this method foo logs messages using Java's logger.My requirement is to call foo for 3 times from Caller and capture/redirect the log messages into 3 log files.
    But only the first log file is capturing the log messages(from logger) and other two are not ?
    Plz suggest if I am doing somethin wrong here ?
    Caller.java
    package project2;
    import java.io.File;
    import java.io.FileNotFoundException;
    import java.io.PrintStream;
    import java.lang.reflect.Method;
    public class Caller {
        public Caller() {
        public static void main(String[] args) throws Exception {
            Caller caller = new Caller();
            for (int i = 0 ;i<3 ;i++ )  {
                caller.createLogStream(i);
                System.setOut(caller.getPs());
                System.setErr(caller.getPs());
                /*****************Invoking Util.java*****************************/
                Class clas = Class.forName("project2.Util");
                Method m = clas.getMethod("foo",null);
                Object obj =clas.newInstance();
                m.invoke(obj,null);
        public void createLogStream(int i) throws FileNotFoundException {
            ps = new PrintStream(new File(System.getenv("HOME")+File.separator+"MyLog"+i+".log"));
        public void closeLogStream(){
            ps.close();
            ps = null;
        private PrintStream ps = null;
        public PrintStream getPs() {
            return ps;
    } Util.java
    package project2;
    import java.util.logging.Logger;
    public class Util {
        Logger logger = null;
        public Util() {
            logger = Logger.getLogger(this.getClass().getName());
        public void foo(){
            System.out.println("Hello out stream");
            System.err.println("Hello error stream");
            logger.info("This is an information");
            logger.warning("This is a warning message");
            logger.severe("This is fatal!! ");
    }First Log file MyLog0.log:
    Hello out stream
    Hello error stream
    Feb 16, 2009 7:55:55 PM project2.Util foo
    INFO: This is an information
    Feb 16, 2009 7:55:55 PM project2.Util foo
    WARNING: This is a warning message
    Feb 16, 2009 7:55:55 PM project2.Util foo
    SEVERE: This is fatal!!
    Feb 16, 2009 7:55:55 PM project2.Util foo
    INFO: This is an information
    Feb 16, 2009 7:55:55 PM project2.Util foo
    WARNING: This is a warning message
    Feb 16, 2009 7:55:55 PM project2.Util foo
    SEVERE: This is fatal!!
    Feb 16, 2009 7:55:55 PM project2.Util foo
    INFO: This is an information
    Feb 16, 2009 7:55:55 PM project2.Util foo
    WARNING: This is a warning message
    Feb 16, 2009 7:55:55 PM project2.Util foo
    SEVERE: This is fatal!! Other 2 log files have only this much
    Hello out stream
    Hello error stream

    A stale Connection Factory or Connection Handle may be used in SOA 11g
    Regards,
    Anuj

  • Using List Class in java.awt / java.util ?

    have a program that:
    import java.util.*;
    List list = new LinkedList();
    list = new ArrayList();
    ... read a file and add elements to array
    use a static setter
    StaticGettersSetters.setArray(list);
    next program:
    import java.awt.*;
    public static java.util.List queryArray =
    StaticGettersSetters.getArray();
    If I don't define queryArray with the package and class, the compiler
    gives an error that the List class in java.awt is invalid for queryArray.
    If I import the util package, import java.util.*; , the compiler
    gives an error that the list class is ambiguous.
    Question:
    If you using a class that exists in multiple packages, is the above declaration of queryArray the only way to declare it ?
    Just curious...
    Thanks for your help,
    YAM-SSM

    So what you have to do is explicitly tell the compiler which one you really want by spelling out the fully-resolved class name:
    import java.awt.*;
    import java.sql.*;
    import java.util.*;
    public class ClashTest
        public static void main(String [] args)
            java.util.Date today    = new java.util.Date();
            java.util.List argsList = Arrays.asList(args);
            System.out.println(today);
            System.out.println(argsList);
    }No problems here. - MOD

  • Fatal Error: missing resource: java.util.PropertyResourceBundle =Urgent

    Hi all,
    In the JSP ,if I include the statement <%@ page import="jack.samples.*" %>
    it is throwing following error:
    This is the Error Message from the Exception:
         Server caught unhandled exception from servlet [BaseServlet]: Server caught
         unhandled exception from servlet [CategoryDisplay]: Server caught unhandled
         exception from servlet [jsp]: Fatal Error: missing resource: java.util.PropertyResourceBundle
         I am using Websphere 3.5 on Windows NT.
         can somebody please help me what is going wrong here ???I am stopped at
         this problem for last 2 days.
    Thanks
    Jack

    Hi,
    Finally I was able to resolve after adding this jar file to the classfile
    path of the application.
    Now,I am trying to access use linkTable.add(new Item(222,"222","333",12.33)) in JSP.
    where linkTable is a LinkedList.
    It fails giving following error:
    This is the Error Message from the Exception:
    Server caught unhandled exception from servlet [BaseServlet]: Server caught unhandled exception from servlet : Server caught unhandled exception from servlet [jsp]: Compilation of "softproduct.jsp" failed: d:\ibm\WAServer\temp\default_host\WCSServlets\_jameco_2F_softproduct_2E_jsp_jsp_2.java:824: No constructor matching Item&#40;int, java.lang.String, java.lang.String, double&#41; found in class jack.samples.Item. linkTab.add&#40;new Item&#40;2222,"222","222",22.33&#41;&#41;&#59; ^ Note: d:\ibm\WAServer\temp\default_host\WCSServlets\_jameco_2F_softproduct_2E_jsp_jsp_2.java uses or overrides a deprecated API. Recompile with "-deprecation" for details. 1 error, 1 warning
    I dont understand why it is failing to add Item object to LinkedList.
    can somebody help me in the forum in this regard.
    Thanks
    Jack

  • Is there a Java utility class to help with data management in a desktop UI?

    Is there a Java utility class to help with data management in a desktop UI?
    I am writing a UI to configure a network device that will be connected to the serial port of the computer while it is being configured. There is no web server or database for my application. The UI has a large number of fields (50+) spread across 16 tabs. I will write the UI in Java FX. It should run inside the browser when launched, and issue commands to the network device through the serial port. A UI has several input fields spread across tabs and one single Submit button. If a field is edited, and the submit button clicked, it issues a command and sends the new datum to the device, retrieves current value and any errors. so if input field has bad data, it is indicated for example, the field has a red border.
    Is there a standard design pattern or Java utility class to accomplish the frequently encountered, 'generic' parts of this scenario? lazy loading, submitting only what fields changed, displaying what fields have errors etc. (I dont want to reinvent the wheel if it is already there). Otherwise I can write such a class and share it back here if it is useful.
    someone recommended JGoodies Bindings for Swing - will this work well and in FX?

    Many thanks for the reply.
    In the servlet create an Arraylist and in th efor
    loop put the insances of the csqabean in this
    ArrayList. Exit the for loop and then add the
    ArrayList as an attribute to the session.I am making the use of Vector and did the same thing as u mentioned.I am using scriplets...
    >
    In the jsp retrieve the array list from the session
    and in a for loop step through the ArrayList
    retrieving each CourseSectionQABean and displaying.
    You can do this in a scriptlet but should also check
    out the jstl tags.I am able to remove this problem.Thanks again for the suggestion.
    AS

  • Doubt in java.util.logging

    Hi,
    I have doubt in logging api provided in java 1.4.
    I have a simple program to get the logger and output log into it.
    This is how the program looks.
    LogTest.java
    import java.util.logging.*;
    import java.util.*;
    public class LogTest {
    public static void main(String args[]) {
         LogManager manager = LogManager.getLogManager();
         Logger l = manager.getLogger("global");
         System.out.println(l);
         l.severe("Test");
         System.out.println(manager.getLogger("ivy"));
         System.out.println(manager.getLogger("test"));
    I able to get the instance of the global logger, but im not able to get instance of other logger. I getting null for all the other logger
    test.properites
    =================
    handlers = java.util.logging.ConsoleHandler
    java.util.logging.ConsoleHandler.level=INFO
    java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
    ivy.level = INFO
    .ivy.level = INFO
    =================
    Compilation Command
    java -Djava.util.logging.config.file=C:\WorkSpace\test.properties LogTest Output:
    java.util.logging.Logger@13f5d07
    Jan 25, 2006 7:19:24 PM LogTest main
    SEVERE: Test
    null
    null
    I also tried the same with no config properties, Still im getting the null for logger.
    Can I know is there anything that im missing. Is there any property that must be set or do i hav set some config properties.
    Thanks,
    Siva

    Well, basically that's part of the formatdefinition
    that Properties uses. If you don't do it, then you
    aren't really using Properties format and you'llhave
    to do your own IO.Thanks for the reply. Is there anyother api or class
    that can be used to resolve my problem.What is the problem? A character is escaped, but you will get : when you read the value. You don't have a problem as long as all reading / writing is done through that class.

  • Query not running in sql developer, neither connecting to database. Following error - java.util.UnknownFormatConversionException: Conversion = '0'. Please reply soon.

    when i try to connect to oracle 11g rdbms, following error occurs -->
    1. sql developer version - 4.0.3.16 (jdk - jdk1.7.0_51 externally installed) -- newly installed, giving following error when try to connect to oracle 11g rdbms.
    2. sql developer version - 3.1.07.42 (jre1.6.0 included) -- used to run earlier.
    java.util.UnknownFormatConversionException: Conversion = '0'
      at java.util.Formatter.checkText(Formatter.java:2547)
      at java.util.Formatter.parse(Formatter.java:2533)
      at java.util.Formatter.format(Formatter.java:2469)
      at java.util.Formatter.format(Formatter.java:2423)
      at java.lang.String.format(String.java:2797)
      at oracle.dbtools.raptor.backgroundTask.internal.SimpleRaptorTaskUI.getFormattedTime(SimpleRaptorTaskUI.java:288)
      at oracle.dbtools.raptor.backgroundTask.internal.RaptorTaskUI.setState(RaptorTaskUI.java:43)
      at oracle.dbtools.raptor.backgroundTask.internal.SimpleRaptorTaskUI.<init>(SimpleRaptorTaskUI.java:63)
      at oracle.dbtools.raptor.backgroundTask.internal.RaptorTaskUI.<init>(RaptorTaskUI.java:36)
      at oracle.dbtools.raptor.backgroundTask.ui.TaskProgressViewer$4.<init>(TaskProgressViewer.java:346)
      at oracle.dbtools.raptor.backgroundTask.ui.TaskProgressViewer.createTaskUI(TaskProgressViewer.java:346)
      at oracle.dbtools.raptor.backgroundTask.RaptorTaskManager.initViewers(RaptorTaskManager.java:373)
      at oracle.dbtools.raptor.backgroundTask.RaptorTaskManager.access$400(RaptorTaskManager.java:45)
      at oracle.dbtools.raptor.backgroundTask.RaptorTaskManager$4.run(RaptorTaskManager.java:299)
      at oracle.dbtools.raptor.backgroundTask.RaptorTaskManager.invokeInDispatchThreadIfNeeded(RaptorTaskManager.java:313)
      at oracle.dbtools.raptor.backgroundTask.RaptorTaskManager.addTask(RaptorTaskManager.java:302)
      at oracle.dbtools.raptor.backgroundTask.RaptorTaskManager.addTask(RaptorTaskManager.java:200)
      at oracle.dbtools.raptor.backgroundTask.RaptorTaskManager.addTask(RaptorTaskManager.java:161)
      at oracle.dbtools.worksheet.editor.OpenWorksheetWizard.invoke(OpenWorksheetWizard.java:425)
      at oracle.ide.wizard.WizardManager.invokeWizard(WizardManager.java:446)
      at oracle.ide.wizard.WizardManager.invokeWizard(WizardManager.java:390)
      at oracle.dbtools.worksheet.editor.WorksheetOpenController$1.run(WorksheetOpenController.java:84)
      at oracle.dbtools.worksheet.editor.WorksheetOpenController.openWorksheetWizard(WorksheetOpenController.java:90)
      at oracle.dbtools.worksheet.editor.WorksheetOpenController.handleEvent(WorksheetOpenController.java:49)
      at oracle.ide.controller.IdeAction$ControllerDelegatingController.handleEvent(IdeAction.java:1482)
      at oracle.ide.controller.IdeAction.performAction(IdeAction.java:663)
      at oracle.ide.controller.IdeAction.actionPerformedImpl(IdeAction.java:1153)
      at oracle.ide.controller.IdeAction.actionPerformed(IdeAction.java:618)
      at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2018)
      at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2341)
      at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402)
      at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
      at javax.swing.AbstractButton.doClick(AbstractButton.java:376)
      at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:833)
      at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:877)
      at java.awt.Component.processMouseEvent(Component.java:6505)
      at javax.swing.JComponent.processMouseEvent(JComponent.java:3320)
      at java.awt.Component.processEvent(Component.java:6270)
      at java.awt.Container.processEvent(Container.java:2229)
      at java.awt.Component.dispatchEventImpl(Component.java:4861)
      at java.awt.Container.dispatchEventImpl(Container.java:2287)
      at java.awt.Component.dispatchEvent(Component.java:4687)
      at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4832)
      at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4492)
      at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4422)
      at java.awt.Container.dispatchEventImpl(Container.java:2273)
      at java.awt.Window.dispatchEventImpl(Window.java:2719)
      at java.awt.Component.dispatchEvent(Component.java:4687)
      at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:735)
      at java.awt.EventQueue.access$200(EventQueue.java:103)
      at java.awt.EventQueue$3.run(EventQueue.java:694)
      at java.awt.EventQueue$3.run(EventQueue.java:692)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
      at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
      at java.awt.EventQueue$4.run(EventQueue.java:708)
      at java.awt.EventQueue$4.run(EventQueue.java:706)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
      at java.awt.EventQueue.dispatchEvent(EventQueue.java:705)
      at oracle.javatools.internal.ui.EventQueueWrapper._dispatchEvent(EventQueueWrapper.java:169)
      at oracle.javatools.internal.ui.EventQueueWrapper.dispatchEvent(EventQueueWrapper.java:151)
      at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
      at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
      at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
      at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)

    Around a month ago, a similar question appeared on Jeff's block... look for checkText in http://www.thatjeffsmith.com/ask-a-question/
    There was no resolution there, so (as the SQL Developer code in that area has not changed) I would tend to think it might have something to do with
    1. Your Locale affecting the Formatter class's parsing of that pattern; or
    2. A bug in the jdk version in use, probably also related to the Locale.
    I recommend upgrading to the latest jdk1.7.0_xx update.  If that does not solve the issue, then try changing the Locale.

  • Java.util.logging: write to one log file from many application (classes)

    I have a menuapp to launch many applications, all running in same JVM and i want to add logging information to them, using java.util.logging.
    Intention is to redirect the logginginfo to a specific file within the menuapp. Then i want all logging from all applications written in same file. Finally, if needed (but i don't think it is), i will include code to write logging to specific file per app (class). The latter is probably not neccessary because there are tools to analyse the logging-files and allow to select filters on specific classes only.
    The applications are in their own packages/jars and contain following logging-code:
            // Redirect error output
            try {
                myHandler = new FileHandler("myLogging.xml",1000000,2);
            } catch (IOException e) {
              System.out.println("Could not create file. Using the console handler");
            myLogger.addHandler(myHandler);
            myLogger.info("Our first logging message");
            myLogger.severe("Something terrible happened");
            ...When i launch the menuapplication, it writes info to "myLogging.xml.0"
    but when i launch an application, the app writes info to "myLogging.xml.0.1"
    I already tried to leave out the creation of a new Filehandler (try/catch block in code above) but it doesn't help.
    Is it possible to write loginfo to same specific file?

    You should open/close it somehow at every write from different processes.
    But I personally prefer different file names to your forced merging, though.

  • Java.util.MissingResourceException: Can't find bundl :ERROR plz Help

    hey guys am trying to connect to my data base and view data toa jsp page but i got this error :
    Exception report
    message
    descriptionThe server encountered an internal error () that prevented it from fulfilling this request.
    exception
    org.apache.jasper.JasperException: java.util.MissingResourceException: Can't find bundle for base name DataBase, locale en_US
    root cause
    java.util.MissingResourceException: Can't find bundle for base name DataBase, locale en_US
    note The full stack traces of the exception and its root causes are available in the Sun Java System Application Server 9.1 logs.
    here is the code database _proper
    drivername=oracle.jdbc.driver.OracleDriver
    dataSourceName=jdbc/orcl/WOH
    dsLookupPrefix=WOH.getstring("dslookupprefix");
    user=SYSTEM
    password=SYSTEM
    location=192.168.1.3
    port=1521
    sid=ORCL
    and here is the Dao connection class
    package version.dao;
    import java.util.*;
    //to provide JDBC classes
    import java.sql.*;
    * @author freddy
    public class DAODirect {
    * Insert the type's description here.
    * Creation date: (12/25/2006 12:13:56 PM)
    * @author: Administrator
         private Connection connection = null;
         private Statement statement = null;
         private String driverName =null;// "oracle.jdbc.driver.OracleDriver";//null;
         private String url =null;//"jdbc:oracle:thin:scott/tiger@localhost:1521:ORCL";//null;
         private ResultSet rs = null;
         private String columnNames[];
         private int columnCount;
         private Object[] record;
         * PFSDataBase constructor comment.
         public DAODirect() {
              super();
              ResourceBundle database = ResourceBundle.getBundle("DataBase");
    //1 get the driver name
              driverName = database.getString("drivername");
              String user = database.getString("user");
              String password = database.getString("password");
              String location = database.getString("location");
              String port = database.getString("port");
              String sid = database.getString("sid");
    //String dataSourceName=database.getString("dataSourceName");
    //2- get the Connection url
              url =
                   "jdbc:oracle:thin:"
                        + user
                        + "/"
                        + password
                        + "@"
                        + location
                        + ":"
                        + port
                        + ":"
                        + sid;
              System.out.println("++++++++"+url);
    System.out.println("++++++++"+url);
         public void closeStatement() {
              try {
                   if (statement != null) {
                        statement.close();
                        statement = null;
              } catch (Exception e) {
         public void commitDB() throws Exception{
              connection.commit();     
         public boolean connect() throws Exception {
              try {
                   if (connection == null) {
    //1- loading of JDBC Drivers
                        Class.forName(driverName);
                        System.out.println(url);
    //this line =conn = DriverManager.getConnection(
    // "jdbc:oracle:thin:@noizmaker:1521:osiris",
    // "scott", "tiger");
    //2- Establish Connection
                        connection = DriverManager.getConnection(url);
                        return true;
                   } else {
                        throw (
                             new Exception("connection is not disconnected, you have to disconnect this connection before reconnecting it again"));
              } catch (SQLException e) {
                   e.printStackTrace();
                   throw (new Exception("Unable to connect to database,Error Loading Driver"));
         public void createStatement() throws Exception {
              if (statement != null) {
                   closeStatement();
              if (connection == null) {
                   throw (new Exception("database is not connected"));
              statement = connection.createStatement();//3-bulit_in funnction that create and send sql statment
         public void disconnect() throws Exception {
              if (connection != null) {
                   try {
                        connection.close();
                        connection = null;
                   } catch (Exception e) {
                   //isConnected = false;
              } else {
                   throw (new Exception("can not disconnect database"));
    // ResultSet is: A table of data representing a database result set, which is usually generated by executing a statement that queries the database
         public ResultSet execute(String query) throws Exception {
              if (connection == null) {
                   throw (new Exception("database is not connected"));
              if (statement == null) {
                   throw (new Exception("statement is not created"));
              return statement.executeQuery(query);//bulit_in funnction that 4-execute given sql statment
         public void getColumnNames(ResultSet result) throws Exception {
              try {
    //An object that can be used to get information about the types and properties of the columns in a ResultSet object.
                   ResultSetMetaData resultsMetaData = result.getMetaData();
                   columnCount = resultsMetaData.getColumnCount();
                   columnNames = new String[columnCount];
                   for (int i = 1; i < columnCount + 1; i++) {
                        columnNames[i - 1] = resultsMetaData.getColumnName(i).trim();//trim to remove whaite space
              } catch (Exception e) {
                   throw (new Exception("Result Set Columns " + e.getMessage()));
         public Connection getConnection(){
              return connection;     
         public void rollBack() throws Exception{
              connection.rollback();     
         public Vector rsToVector(ResultSet rs) throws Exception {
              getColumnNames(rs);
              Vector resultSetData = new Vector();
              resultSetData.addElement(columnNames);
              try {
                   this.record = new Object[columnCount];
                   while (rs.next()) {
    //ave each raw
                        Object[] record = new Object[columnCount];
                        for (int i = 1; i < columnCount + 1; i++) {
                             Object entry = rs.getObject(i);
                             record[i - 1] = entry;
    // here we print the whole tabel after we save each record in record[]
                        resultSetData.addElement(record);
                   return resultSetData;
              } catch (Exception e) {
                   resultSetData.clear();
                   throw (new Exception("Result Set : " + e.getMessage()));
         public void setAutoCommit(boolean commitType) throws Exception{
              connection.setAutoCommit(commitType);     
         public boolean update(String query) throws Exception {
              if (connection == null) {
                   throw (new Exception("database is not connected"));
              try {
    //create query and execute it
                   createStatement();
                   statement.execute(query);
                   return true;
              } catch (Exception e) {
                   throw (
                        new Exception(
                             "Error in manipulating query :" + e.getMessage()));
              } finally {
                   closeStatement();
    * To change this template, choose Tools | Templates
    * and open the template in the editor.
    package version.dao;
    import java.sql.ResultSet;
    import java.sql.Connection;
    import java.sql.Statement;
    import java.sql.SQLException;
    import javax.sql.DataSource;
    import javax.naming.InitialContext;//unknown
    import java.util.ResourceBundle;//unknown
    * @author freddy
    * This is the Data Access Object (DAO), which deals with all Database transactions,
    * connections,and pooling (through Data Source implementation).
    * This class configured through the database.properties file
    * which contains all the database parameters
    * @author: Tariq Qasem
    public class DAO {
         private Connection connection = null;
         private Statement statement = null;
         private String dataSourceName =null; //MyDataSource; //null;
         private String dsLookupPrefix = null;//java:comp/env/;
    //null;
         private ResultSet rs = null;
         * DAO constructor comment.
         public DAO() {
              super();
              ResourceBundle database = ResourceBundle.getBundle("DataBase");
              dataSourceName = database.getString("dataSourceName");
              dsLookupPrefix = database.getString("dsLookupPrefix");
         * @param request PortletRequest
         * @return void
         * this method close pooled statement
         public void closeStatement() {
              try {
                   if (statement != null) {
                        statement.close();
                        statement = null;
              } catch (Exception e) {
         * @param request PortletRequest
         * @return boolean
         * this method connects to the database
         public boolean connect() throws Exception {
              try {
                   if (connection == null) {
                        InitialContext ctx = new InitialContext();
                   DataSource ds = (DataSource) ctx.lookup(dsLookupPrefix+dataSourceName);
                        connection = ds.getConnection();
                        return true;
                   } else {
                        throw (
                             new Exception("connection is not disconnected, you have to disconnect this connection before reconnecting it again"));
              } catch (SQLException e) {
                   e.printStackTrace();
                   throw (new Exception("Unable to connect to database"));
         public void createStatement() throws Exception {
              if (statement != null) {
                   closeStatement();
              if (connection == null) {
                   throw (new Exception("database is not connected"));
              statement = connection.createStatement();
         * @param request PortletRequest
         * @return void
         * this method disconnect the database connection
         public void disconnect() throws Exception {
              if (connection != null) {
                   try {
                        connection.close();
                        connection = null;
                   } catch (Exception e) {
              } else {
                   throw (new Exception("can not disconnect database"));
         * @param request PortletRequest
         * @return boolean
         * this method updates (executes) Insert and Updates queries on the database
    /*     public boolean update(String query) throws Exception {
              if (connection == null) {
                   throw (new Exception("database is not connected"));
              try {
                   createStatement();
                   statement.execute(query);
                   return true;
              } catch (Exception e) {
                   throw (
                        new Exception(
                             "Error in manipulating query :" + e.getMessage()));
              } finally {
                   closeStatement();
         public int update(String query) throws Exception {
              int records = 0;
              if (connection == null) {
                   throw (new Exception("database is not connected"));
              try {
                   createStatement();
                   records = statement.executeUpdate(query);
                   return records;
              } catch (Exception e) {
                   throw (
                        new Exception(
                             "Error in manipulating query :" + e.getMessage()));
              } finally {
                   closeStatement();
         * @param request PortletRequest
         * @return ResultSet
         * this method executes select queries on the database
         public ResultSet execute(String query) throws Exception {
              if (connection == null) {
                   throw (new Exception("database is not connected"));
              if (statement == null) {
                   throw (new Exception("statement is not created"));
              return statement.executeQuery(query);
         * @param request PortletRequest
         * @return void
         * this method to set the commit transaction on the database to be auto
         public void setAutoCommit(boolean commitType) throws Exception{
              connection.setAutoCommit(commitType);     
         * @param request PortletRequest
         * @return void
         * this method commit database transaction
         public void commitDB() throws Exception{
              connection.commit();     
         * @param request PortletRequest
         * @return void
         * this method rollback database transaction
         public void rollBack() throws Exception{
              connection.rollback();     
         * @param request PortletRequest
         * @return Connection
         * this method return the database connection as java object
         public Connection getConnection(){
              return connection;     
    and this is my jsp page:
    <%--
    Document : index
    Created on : Mar 16, 2008, 10:14:55 AM
    Author : freddy
    --%>
    <%@page contentType="text/html" pageEncoding="UTF-8"%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>JSP Page</title>
    </head>
    <body>
    <h2>Hello World!</h2>
    <%
    version.dao.DAODirect dao=new version.dao.DAODirect();
    try
    boolean connected = dao.connect();
    dao.createStatement();
    String query = " SELECT ID,NAME FROM version";
    java.sql.ResultSet rs = dao.execute(query);
    while(rs.next()){
    out.println(rs.getInt("P_ID")+" ");
    out.println(rs.getString("P_FN")+"<BR>");
    dao.closeStatement();
    dao.disconnect();
    catch(Exception e)
    out.print(e.getMessage());
    %>
    </body>
    </html>
    plz guys help me i need this for my graduation project also if anyone know kind of tutorialsfor building J2me/J2EE application using wifi plzzzsend me links or anything ,thx in advance

    This can happen after modifying the calendar properties and not reloading the application. Try reloading or restarting the application. This could also mean the Calendar.properties file has been moved, deleted, or become corrupted. A default properties file can be found at:
    "Tomcat-install-dir"\webapps\"your-web-application"\WEB-INF\classes\defaultPropFile\. Copy this file to: "Tomcat-install-dir"\webapps\"your-web-application"\WEB-INF\classes\. Stop and restart the web server. From a browser, run "hostname"/"your-web-application"/src/setupCalendar.jsp.

  • How can I create an instance of "java.util.prefs.WindowsPreferences"?

    Hi All,
    I was trying to find out a way to access the Windows Registry to add soome keys and and later add a string.
    I found WindowsPreferences might be useful in the above mentioned context.
    I was trying to create an instance of it, but when I import the class, it says it is invisible.
    Can anyone let me know how to instantiate this class.
    Note:- Under the same package "java.util.prefs" we have another class "Preferences", Iam able to import this one and use it in my code.
    Thank You.
    Regards,
    Suman.H

    It's true that Preferences uses the Registry on Windows systems, that does not mean you can use it as a Registry API. The only part of the Registry you can access are those branches that are set aside for java.util.prefs: HKLM\Software\JavaSoft\Prefs and HKCU\Software\JavaSoft\Prefs. IF you need to access other parts of the Registry, you'll need to use JNI or a separate Windows Registry library.

  • Bug on native code of OJVM java.util.zip.CRC32.updateBytes(CRC32.java)

    I want to unzip OpenOffice 1.0 files inside the OJVM but it fails into the native method java.util.zip.CRC32.updateBytes(CRC32.java).
    The first execution of the code runs OK, but the second not.
    After a long wait it shutdown the connection and the oracle trace file shows an stack trace like this:
    *** 2003-04-18 11:31:31.926
    *** SESSION ID:(17.97) 2003-04-18 11:31:31.926
    java.lang.IllegalArgumentException
    at java.util.zip.CRC32.updateBytes(CRC32.java)
    at java.util.zip.CRC32.update(CRC32.java)
    at java.util.zip.ZipInputStream.read(ZipInputStream.java)
    at oracle.xml.parser.v2.XMLByteReader.fillByteBuffer(XMLByteReader.java:354)
    at oracle.xml.parser.v2.XMLUTF8Reader.fillBuffer(XMLUTF8Reader.java:142)
    at oracle.xml.parser.v2.XMLByteReader.saveBuffer(XMLByteReader.java:448)
    at oracle.xml.parser.v2.XMLReader.fillBuffer(XMLReader.java:2012)
    at oracle.xml.parser.v2.XMLReader.skipWhiteSpace(XMLReader.java:1800)
    at oracle.xml.parser.v2.NonValidatingParser.parseMisc(NonValidatingParser.java:305)
    at oracle.xml.parser.v2.NonValidatingParser.parseProlog(NonValidatingParser.java:274)
    at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:254)
    at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:225)
    at com.prism.cms.frontend.EditPropertiesActions.processUpload(EditPropertiesActions.java:1901)
    Exception signal: 11 (SIGSEGV), code: 1 (Address not mapped to object), addr: 0x6d3a74a0, PC: [0x40263600, eomake_reference_to_eobjec
    t()+80]
    Registers:
    %eax: 0x54a54000 %ebx: 0x40429c20 %ecx: 0x54a546bf
    %edx: 0x6d3a7478 %edi: 0x402b27d0 %esi: 0x45c718ac
    %esp: 0xbfffbf20 %ebp: 0xbfffbf48 %eip: 0x40263600
    %efl: 0x00010206
    The code of the java method is:
    public static void processUpload(String id_page, String longname,
    String filename, String filetype,
    String s00)
    throws SQLException {
    Integer p_id = new Integer(id_page);
    String toSource;
    XMLDocument doc = null;
    DOMParser theParser = null;
    InputStream XSLStream = null;
    BufferedWriter out = null;
    #sql { select path||name||'.html' into :toSource from pages where id_page=:p_id };
    if ("Cancel".equalsIgnoreCase(s00)) {
    Jxtp.redirecUrl("/dbprism/ldoc/live/edit.html?p_source="+toSource);
    return;
    if ("no-file".equals(filename) && "no-contenttpye".equals(filetype)) {
    Jxtp.redirecUrl("/dbprism/ldoc/live/edit.html?p_source="+toSource);
    return;
    if ("xml".equalsIgnoreCase(filetype))
    #sql { call CMSj.moveFromUpload(:filename,:p_id) };
    else if ("sxw".equalsIgnoreCase(filetype)) {
    XSLProcessor processor = new XSLProcessor();
    XSLStylesheet theXSLStylesheet = null;
    BLOB locator = null;
    // open sxw file, it will be in zip format with a file named content.xml
    // then convert content.xml to document-v10.dtd with an stylesheet
    #sql { select blob_content into :locator from wpg_document where name = :filename for update };
    ZipInputStream zin = new ZipInputStream(locator.binaryStreamValue());
    ZipEntry entry;
    try {
    while((entry=zin.getNextEntry())!=null)
    if ("content.xml".equalsIgnoreCase(entry.getName())) {
    Integer newVersion;
    CLOB dstDoc;
    CMSDocURLStreamHandlerFactory.enableCMSDocURLs();
    try {
    URL inUrl = new URL("cms:/stylesheets/sxw2document-v10.xsl");
    XSLStream = inUrl.openStream();
    // Create the Stylesheet from the stream
    theXSLStylesheet = processor.newXSLStylesheet(XSLStream);
    // Stores the document processing it with the given stylesheet
    theParser = new DOMParser();
    theParser.setValidationMode(theParser.NONVALIDATING);
    theParser.setBaseURL(new URL("cms:/dtd/"));
    theParser.parse(zin);
    doc = theParser.getDocument();
    #sql { SELECT NVL(MAX(version),0)+1 INTO :newVersion FROM content
    WHERE cn_id_page = :p_id };
    #sql { INSERT INTO content( cn_id_page, version, owner, status, source_file,
    file_size, content, created, modified, created_by,
    modified_by)
    VALUES ( :p_id, :newVersion, sys_context('cms_context','user_id'),
    'Uploaded', :filename, 0 , EMPTY_CLOB(), SYSDATE, SYSDATE,
    sys_context('cms_context','user_id'),
    sys_context('cms_context','user_id')) };
    #sql { SELECT content INTO :dstDoc FROM content
    WHERE cn_id_page = :p_id AND version = :newVersion for update };
    #sql { call DBMS_LOB.trim(:inout dstDoc,0) };
    out = new BufferedWriter(dstDoc.getCharacterOutputStream(),dstDoc.getChunkSize());
    processor.processXSL(theXSLStylesheet, doc, new PrintWriter(out));
    #sql { delete from wpg_document where name=:filename };
    } catch (SAXParseException spe) {
    throw new SQLException("processUpload SAXParseException: "+xmlError(spe));
    } catch (SAXException se) {
    throw new SQLException("processUpload SAXException: "+se.getLocalizedMessage());
    } catch (XSLException xsle) {
    throw new SQLException("processUpload XSLException: "+xsle.getLocalizedMessage());
    } finally {
    if (XSLStream!=null)
    XSLStream.close();
    if (theParser!=null)
    theParser = null;
    if (out!=null) {
    out.flush();
    out.close();
    zin.close();
    } catch (IOException ioe) {
    throw new SQLException("processUpload IOException: "+ioe.getLocalizedMessage());
    } finally {
    if (XSLStream!=null)
    XSLStream = null;
    if (out!=null)
    out = null;
    if (zin!=null)
    zin = null;
    Jxtp.redirecUrl("/dbprism/ldoc/live/edit.html?p_source="+toSource);
    Basically it takes the content from a BLOB column of the wpg_document table, unzip it using java.util.zip package, look for the file content.xml and parse it using Oracle XML toolkit.
    Using an open source utility which replace java.util.package (http://jazzlib.sourceforge.net/) it works perfect because is a pure java application.
    Best regards, Marcelo.
    PD: I am using Oracle 9.2.0.2 on Linux.

    The cause of errors was a dying Westen Digital drive, specially the 48G partition reserved only for $ORACLE_BASE (/dev/sdb3 mounted on /opt/oracle).
    A simple quick scan of unmounted partition (badblocks -v /dev/sdb3) reported more than thousand new bad blocks (compared to the last scan six months ago). Although I strongly believe, specially in the case of WDC drives, that the best utility to "repair" bad blocks is the one that opens a window and prints the message: "Go to the nearest shop and buy a new drive", I was very curious to prove my suspicion just on this drive. After zero-filling the partition with dd, then formatting it (mke2fs -cc) and mounting again, the 11g installation and database creation (on the same partition) successfully completed, performing fast and smoothly. To make sure it was not a casual event, I repeated the installation once again with full success. The database itself is working fine (by now). Well, the whole procedure took me more than four hours, but I'm pretty satisfied. I learned once again - stay away from Western Digital. As Oracle cannot rely on dying drive, my friend is going tomorrow to spend a 150+ euro on two 250G Seagate Barracudas and replace both WDC drives, even though the first drive seems to be healthy.
    In general there is no difference between loading correct data from good disk into bad memory and loading the incorrect data from dying disk into good memory. In both cases the pattern is damaged. For everyone who runs into the problem similar to this, and the cause cannot be easily determined, the rule of thumb must be:
    1. test memory and, if it shows any error, check sockets and test memory modules individually
    2. check disks for bad blocks regardless of the result of memory testing
    Therefore I consider your answer being generally correct.
    Regards
    NJ

Maybe you are looking for

  • Questions regarding how I pay my Line Rental Bill ...

    Hi BT,  I'm currently a BE Broadband customer,  I was a BT Broadband customer back in the days when you had BT Home Hub 1.0 and 8mb packages which i was only getting like 5-6mb, 0.3mb upload and constant speed caps on my connection to 1mb.  You guys

  • What is happening with quote substitution in Mail since Mountain Lion?

    What is happening with quote substitution in Mail since Mountain Lion? Now, whenever I type an apostrophe and it's replaced with a smart quote, it creates an unwanted space within my word and starts typing from there. It will also revert the font fro

  • Is the new iMac USB 2.0 Bootable ???

    Two questions really: Is it possible to boot the new iMac from an external USB 2.0 device ??? If it is possible, how do I use the install disks that came with my new iMac to install a copy of Mac OS 10.4.10 onto an external USB 2.0 hard drive connect

  • Deploy failed on Server AdminServer

    I am deploying WebLogicFusionDemo. I using Jdev 11.1.1.4 and SOA Suite 11.1.1.4 to deploy Supplemental Instructions for Running Fusion Order Demo for Oracle SOA Suite 11g Release 1 (11.1.1.4.0) However, in the step of running "build.xml -> server-set

  • SAP SD, MM, HR

    Hi Friends, I would like to start learning SAP, looking for better opportunity and grow into the same. I would like to share my past experience. Please help me to select SAP module for my career. Working as a Sr. Business Development Executive (from