File is not a normal file exception while using HttpClient()

Hi All,
I would like to upload few files from the end user desktop machine to a unix server. This process will be done during the execution of a portal application (PAR). I was just trying my hands at the following code, but it gives me <b>File is not a normal file exception</b>.
public void doContent(IPortalComponentRequest request, IPortalComponentResponse response)
         response.write("Hi Sandip.....");
         /** reading file informations */
         final String serverURL = "serverURL";
          PostMethod mPost=null;
         try {
               HttpClient httpCl = new HttpClient();
               mPost = new PostMethod(serverURL);
               File file1 = new File("D:\JavaScreen.jpeg");
               response.write("<BR>you selected the file::"+file1.getAbsolutePath());
               mPost.getParams().setBooleanParameter(HttpMethodParams.USE_EXPECT_CONTINUE,true);               
               response.write("<BR>Uploading file to server....");
               //Part fileParts = new FilePart(file1.getName(),file1);               
               FilePart[] filePart = {
                         new FilePart(file1.getName(),file1) //add multiple files here
               mPost.setRequestEntity(new MultipartRequestEntity(filePart,mPost.getParams()));     
               httpCl.getHttpConnectionManager().getParams().setConnectionTimeout(5000);
               int statusCode = httpCl.executeMethod(mPost);
               if(statusCode==HttpStatus.SC_OK){
                    response.write("<BR>upload done:"+mPost.getResponseBodyAsString());
               }else{
                    response.write("<BR>upload failed:"+HttpStatus.getStatusText(statusCode));
               mPost.releaseConnection();
          } catch (HttpException e) {
               // TODO Auto-generated catch block
               //e.printStackTrace();
               response.write("Excp1:"+e.getLocalizedMessage());
               mPost.releaseConnection();
          } catch (IOException e) {
               // TODO Auto-generated catch block
               //e.printStackTrace()
               response.write("Excp2:"+e.getLocalizedMessage());
               response.write("Excp3::"+e.getCause());
               mPost.releaseConnection();
          }finally{
               mPost.releaseConnection();
This is written inside a portal application. While running this code, it gives an output
Hi Sandip.....
you selected the file::D:JavaScreen.jpeg
Uploading file to server....Excp2:File is not a normal file.Excp3::null
What could be the problem? I tried with 2-3 files.
Would appreciate a reply.
Regards
Sandip Agarwal

Hi,
you can check this link.
<a href="http://svn.apache.org/viewvc/jakarta/httpcomponents/oac.hc3x/trunk/src/examples/">HttpClient sample codes</a>
regards
Vivek Nidhi

Similar Messages

  • Help - Premature end of file Exception while using saaj

    Hi Everyone,
    I have written a sample saaj client, with a string as an attachment and trying to send it to a servlet as shown in the example below:
    * SaajClient.java
    * Created on June 23, 2004, 5:49 PM
    * @author Krishna Menon
    import javax.xml.soap.*;
    import javax.xml.messaging.URLEndpoint;
    public class SaajClient {
    public SaajClient() throws Exception
    try{
    SOAPMessage soapMessage = MessageFactory.newInstance().createMessage();
    SOAPPart soapPart = soapMessage.getSOAPPart();
    SOAPEnvelope envelope = soapPart.getEnvelope();
    SOAPHeader header = envelope.getHeader();
    SOAPBody body = envelope.getBody();
    header.detachNode();
    String str = "Something a;alskdjf;laksjdfl;akjsdf;lk ;alskdjfl;asjdfl;ajk ;kdls a;kl";
    if(soapMessage != null)
    AttachmentPart attachment = soapMessage.createAttachmentPart();
    attachment.setContentType("text/plain");
    attachment.setContent(str,"text/plain");
    attachment.setContentId("Sample_String");
    soapMessage.addAttachmentPart(attachment);
    soapMessage.saveChanges();
    SOAPConnection connection = SOAPConnectionFactory.newInstance().createConnection();
    URLEndpoint endpoint = new URLEndpoint("http://10.2.1.132:8080/WebServices/servlet/AttachmentReceiver");
    SOAPMessage response = connection.call(soapMessage,endpoint);
    response.writeTo(System.out);
    }catch(Exception e)
    System.out.println("Caught in constructor");
    e.printStackTrace();
    public static void main(String args[])
    try
    SaajClient client = new SaajClient();
    }catch(Exception e)
    e.printStackTrace();
    When I run the above program, it is giving the following exception:
    Caught in constructor
    javax.xml.soap.SOAPException: org.xml.sax.SAXParseException: Premature end of file.
    at org.apache.axis.soap.SOAPConnectionImpl.call(SOAPConnectionImpl.java:110)
    at SaajClient.<init>(SaajClient.java:58)
    at SaajClient.main(SaajClient.java:74)
    Caused by: org.xml.sax.SAXParseException: Premature end of file.
    at org.apache.axis.AxisFault.makeFault(AxisFault.java:129)
    at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:543)
    at org.apache.axis.Message.getSOAPEnvelope(Message.java:376)
    at org.apache.axis.client.Call.invokeEngine(Call.java:2583)
    at org.apache.axis.client.Call.invoke(Call.java:2553)
    at org.apache.axis.client.Call.invoke(Call.java:1753)
    at org.apache.axis.soap.SOAPConnectionImpl.call(SOAPConnectionImpl.java:105)
    ... 2 more
    Caused by: org.xml.sax.SAXParseException: Premature end of file.
    at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1139)
    at javax.xml.parsers.SAXParser.parse(SAXParser.java:345)
    at org.apache.axis.encoding.DeserializationContextImpl.parse(DeserializationContextImpl.java:242)
    at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:538)
    ... 7 more
    If anybody has a solution for it, please post it here.
    Thanks in advance,
    With Regards,
    Krishna Menon. B.

    Hi
    Actually the problem is not with the client but with the servlet I think. In the servlet, I am able to retrieve the attachment and print its content. After receiving the Message, I am creating a new message and populating its body with a new child element and returning the message back to the client. Just Before returning the message, I am getting the Axis Fault error in the log file. I am giving the code for the Servlet I have used below:
    * AttachmentReceiver.java
    * Created on June 23, 2004, 7:11 PM
    * @author Krishna Menon
    import java.util.Iterator;
    import javax.servlet.ServletException;
    import javax.xml.messaging.JAXMServlet;
    import javax.xml.messaging.ReqRespListener;
    import javax.xml.soap.AttachmentPart;
    import javax.xml.soap.MessageFactory;
    import javax.xml.soap.SOAPEnvelope;
    import javax.xml.soap.SOAPMessage;
    import javax.xml.soap.SOAPPart;
    import javax.xml.soap.SOAPFactory;
    * Servlet that accepts a SOAP message and looks through
    * its attachments before sending the SOAP part of the message
    * to the console and sending back a response
    * @author Krishna Menon
    public class AttachmentReceiver extends JAXMServlet implements ReqRespListener {
    private MessageFactory fac;
    public void init() throws ServletException {
    try {
    fac = MessageFactory.newInstance();
    catch( Exception ex ) {
    System.out.println("In AttachmentReceiver init");
    ex.printStackTrace();
    throw new ServletException( ex );
    // This is the application code for handling the message.. Once the
    // message is received the application can retrieve the soap part, the
    // attachment part if there are any, or any other information from the
    // message.
    public SOAPMessage onMessage( SOAPMessage message ) {
    System.out.println( "On message called in receiving servlet" );
    try {
    System.out.println( "\nMessage Received: " );
    System.out.println( "\n============ start ============\n" );
    // dump out attachments
    System.out.println( "Number of Attachments: " + message.countAttachments() );
    int i = 1;
    for( Iterator it = message.getAttachments(); it.hasNext(); i++ ) {
    AttachmentPart ap = (AttachmentPart) it.next();
    System.out.println( "Attachment #" + i + " content type : " +
    ap.getContentType() );
    System.out.println("Attachment Content ::"+ap.getContent());
    // dump out the SOAP part of the message
    SOAPPart soapPart = message.getSOAPPart();
    System.out.println( "SOAP Part of Message:\n\n" + soapPart );
    System.out.println( "\n============ end ===========\n" );
    SOAPMessage msg = fac.createMessage();
    SOAPEnvelope env = msg.getSOAPPart().getEnvelope();
    SOAPFactory soapFactory = SOAPFactory.newInstance();
    System.out.println("Before getBody");
    env.getBody().addChildElement(soapFactory.createName("MessageResponse")).addTextNode("From Attachment Servlet"+"\nYour Attachment Received");
    System.out.println("After getBody");
    //addChildElement("MessageResponse").addTextNode("From Attachment Servlet"+"\nYour Attachment Received");
    msg.saveChanges();
    System.out.println("After Msg Save Changes");
    return msg;
    catch( Exception e ) {
    System.out.println("From OnMessage() of AttachmentReceiver");
    e.printStackTrace();
    return null;
    This is generating the following series of errors in the catalina.out (Tomcat4.1 error log ) file:
    On message called in receiving servlet
    Message Received:
    ============ start ============
    Number of Attachments: 1
    Attachment #1 content type : text/plain
    SOAP Part of Message:
    org.apache.axis.SOAPPart@16fdac
    ============ end ===========
    - java.io.IOException:
    AxisFault
    faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
    faultSubcode:
    faultString: java.lang.ClassCastException
    faultActor:
    faultNode:
    faultDetail:
         {http://xml.apache.org/axis/}stackTrace: java.lang.ClassCastException
         at org.apache.axis.message.SOAPBody.outputImpl(SOAPBody.java:173)
         at org.apache.axis.message.SOAPEnvelope.outputImpl(SOAPEnvelope.java:509)
         at org.apache.axis.message.MessageElement.output(MessageElement.java:783)
         at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:270)
         at org.apache.axis.Message.writeTo(Message.java:440)
         at javax.xml.messaging.JAXMServlet.doPost(Unknown Source)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Unknown Source)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(Unknown Source)
         at org.apache.catalina.core.StandardWrapperValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
         at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
         at org.apache.catalina.core.StandardContextValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
         at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
         at org.apache.catalina.core.StandardContext.invoke(Unknown Source)
         at org.apache.catalina.core.StandardHostValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.valves.ErrorReportValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
         at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
         at org.apache.catalina.core.StandardEngineValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
         at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
         at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:594)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:392)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:565)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
         at java.lang.Thread.run(Thread.java:534)
    java.lang.ClassCastException
         at org.apache.axis.AxisFault.makeFault(AxisFault.java:129)
         at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:272)
         at org.apache.axis.Message.writeTo(Message.java:440)
         at javax.xml.messaging.JAXMServlet.doPost(Unknown Source)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Unknown Source)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(Unknown Source)
         at org.apache.catalina.core.StandardWrapperValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
         at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
         at org.apache.catalina.core.StandardContextValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
         at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
         at org.apache.catalina.core.StandardContext.invoke(Unknown Source)
         at org.apache.catalina.core.StandardHostValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.valves.ErrorDispatcherValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.valves.ErrorReportValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
         at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
         at org.apache.catalina.core.StandardEngineValve.invoke(Unknown Source)
         at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(Unknown Source)
         at org.apache.catalina.core.StandardPipeline.invoke(Unknown Source)
         at org.apache.catalina.core.ContainerBase.invoke(Unknown Source)
         at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:223)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:594)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:392)
         at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:565)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
         at java.lang.Thread.run(Thread.java:534)
    Caused by: java.lang.ClassCastException
         at org.apache.axis.message.SOAPBody.outputImpl(SOAPBody.java:173)
         at org.apache.axis.message.SOAPEnvelope.outputImpl(SOAPEnvelope.java:509)
         at org.apache.axis.message.MessageElement.output(MessageElement.java:783)
         at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:270)
         ... 33 more

  • Exception while using unit of work commit

    Hi,
    I have using this code to create a object
    KbAdAlerts alert = new KbAdAlerts();
    alert.setAlertId(kmData.getAlertId());
    alert.setAlertDesc(kmData.getOutcome());
    alert.setAlertLastRevisionDate(KmUtils.convertReviewDate(kmData.getReviewDate()));
    alert.setAlertType(kmData.getAlertType());
    System.out.println("Alert Object :" + alert);
    KbAdAlerts alertClone = (KbAdAlerts) uow.registerObject(alert);
    System.out.println("Clone Alert:" + alertClone);
    uow.printRegisteredObjects();
    uow.commit();
    I am getting exception while using uow.commit(). I have gone into alert object and everything seems to be fine.
    Could you help me in this issue.
    Thanks,
    Ashish
    Exception [TOPLINK-4002] (Oracle TopLink - 10g Release 3 (10.1.3.0.0) (Build 060118)): oracle.toplink.exceptions.DatabaseException
    Internal Exception: java.sql.SQLException: ORA-01400: cannot insert NULL into ("AD_OWNER"."KB_AD_ALERTS"."ALERT_ID")
    Error Code: 1400
    Call:insert into kb_ad_alerts(alert_id, alert_desc, alert_type, alert_last_revision_date)
    values
    (NULL, NULL, NULL, NULL)
    Query:InsertObjectQuery(oracle.ccr.admin.model.KbAdAlerts@6108)
         at oracle.toplink.exceptions.TopLinkException.<init>(TopLinkException.java:46)
         at oracle.toplink.exceptions.DatabaseException.<init>(DatabaseException.java:50)
         at oracle.toplink.exceptions.DatabaseException.sqlException(DatabaseException.java:282)
         at oracle.toplink.internal.databaseaccess.DatabaseAccessor.executeDirectNoSelect(DatabaseAccessor.java:658)
         at oracle.toplink.internal.databaseaccess.DatabaseAccessor.executeNoSelect(DatabaseAccessor.java:707)
         at oracle.toplink.internal.databaseaccess.DatabaseAccessor.basicExecuteCall(DatabaseAccessor.java:496)
         at oracle.toplink.internal.databaseaccess.DatabaseAccessor.executeCall(DatabaseAccessor.java:442)
         at oracle.toplink.publicinterface.UnitOfWork.executeCall(UnitOfWork.java:1603)
         at oracle.toplink.internal.queryframework.DatasourceCallQueryMechanism.executeCall(DatasourceCallQueryMechanism.java:117)
         at oracle.toplink.internal.queryframework.DatasourceCallQueryMechanism.executeCall(DatasourceCallQueryMechanism.java:103)
         at oracle.toplink.internal.queryframework.DatasourceCallQueryMechanism.insertObject(DatasourceCallQueryMechanism.java:238)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.insertObject(DatabaseQueryMechanism.java:355)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.insertObjectForWrite(DatabaseQueryMechanism.java:433)
         at oracle.toplink.queryframework.InsertObjectQuery.executeCommit(InsertObjectQuery.java:60)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.performUserDefinedWrite(DatabaseQueryMechanism.java:622)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.performUserDefinedInsert(DatabaseQueryMechanism.java:586)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.insertObjectForWriteWithChangeSet(DatabaseQueryMechanism.java:479)
         at oracle.toplink.queryframework.WriteObjectQuery.executeCommitWithChangeSet(WriteObjectQuery.java:110)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.executeWriteWithChangeSet(DatabaseQueryMechanism.java:259)
         at oracle.toplink.queryframework.WriteObjectQuery.executeDatabaseQuery(WriteObjectQuery.java:47)
         at oracle.toplink.queryframework.DatabaseQuery.execute(DatabaseQuery.java:603)
         at oracle.toplink.queryframework.DatabaseQuery.executeInUnitOfWork(DatabaseQuery.java:519)
         at oracle.toplink.queryframework.ObjectLevelModifyQuery.executeInUnitOfWorkObjectLevelModifyQuery(ObjectLevelModifyQuery.java:100)
         at oracle.toplink.queryframework.ObjectLevelModifyQuery.executeInUnitOfWork(ObjectLevelModifyQuery.java:72)
         at oracle.toplink.publicinterface.UnitOfWork.internalExecuteQuery(UnitOfWork.java:2532)
         at oracle.toplink.publicinterface.Session.executeQuery(Session.java:981)
         at oracle.toplink.publicinterface.Session.executeQuery(Session.java:938)
         at oracle.toplink.internal.sessions.CommitManager.commitNewObjectsForClassWithChangeSet(CommitManager.java:240)
         at oracle.toplink.internal.sessions.CommitManager.commitAllObjectsWithChangeSet(CommitManager.java:161)
         at oracle.toplink.publicinterface.Session.writeAllObjectsWithChangeSet(Session.java:3123)
         at oracle.toplink.publicinterface.UnitOfWork.commitToDatabase(UnitOfWork.java:1242)
         at oracle.toplink.publicinterface.UnitOfWork.commitToDatabaseWithChangeSet(UnitOfWork.java:1330)
         at oracle.toplink.publicinterface.UnitOfWork.commitRootUnitOfWork(UnitOfWork.java:1097)
         at oracle.toplink.publicinterface.UnitOfWork.commit(UnitOfWork.java:865)
         at oracle.ccr.admin.model.FeedbackServices.writeFeedback(FeedbackServices.java:116)
         at oracle.ccr.admin.view.AlertDetails.updateTables(AlertDetails.java:834)
         at oracle.ccr.admin.view.AlertDetails.commandButton1_action(AlertDetails.java:822)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at com.sun.faces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:126)
         at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:72)
         at oracle.adf.view.faces.component.UIXCommand.broadcast(UIXCommand.java:211)
         at oracle.adf.view.faces.component.UIXCollection.broadcast(UIXCollection.java:94)
         at oracle.adf.view.faces.component.UIXTable.broadcast(UIXTable.java:205)
         at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:267)
         at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:381)
         at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:75)
         at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:90)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:367)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:336)
         at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:196)
         at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:87)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:629)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:376)
         at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:870)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:451)
         at com.evermind.server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:218)
         at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:119)
         at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:112)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at oracle.oc4j.network.ServerSocketAcceptHandler.procClientSocket(ServerSocketAcceptHandler.java:230)
         at oracle.oc4j.network.ServerSocketAcceptHandler.access$800(ServerSocketAcceptHandler.java:33)
         at oracle.oc4j.network.ServerSocketAcceptHandler$AcceptHandlerHorse.run(ServerSocketAcceptHandler.java:831)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)

    Hi,
    I am having a similar problem that results in this stack trace. The funny thing is that it occurs after a session.logout/login and re-read of the object I'm trying to update. The other thing is that if I remove objects from the transaction it just happens somewhere else - on a different object/descriptor. I am attempting to upgrade from 9.03 runtime to the 10.0.3.1 builder/runtime. I am connecting to a Sybase 12.5 db.
    Any ideas on this one?
    Thanks,
    Bret
    This is the sql that is found in the DatasourceCallQueryMechanism. We are not using any custom SQL.
    SQLCall(INSERT INTO Invoice (id, description, billingAddress, customerNote, invoiceNumber, startDate, stopDate, sentDate, commitDate, customerId, dueDate) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?))
    java.lang.NullPointerException
         at oracle.toplink.internal.queryframework.DatasourceCallQueryMechanism.insertObject(DatasourceCallQueryMechanism.java:213)
         at oracle.toplink.internal.queryframework.StatementQueryMechanism.insertObject(StatementQueryMechanism.java:156)
         at oracle.toplink.internal.queryframework.StatementQueryMechanism.insertObject(StatementQueryMechanism.java:170)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.insertObjectForWrite(DatabaseQueryMechanism.java:426)
         at oracle.toplink.queryframework.InsertObjectQuery.executeCommit(InsertObjectQuery.java:65)
         at oracle.toplink.queryframework.InsertObjectQuery.executeCommitWithChangeSet(InsertObjectQuery.java:75)
         at oracle.toplink.internal.queryframework.DatabaseQueryMechanism.executeWriteWithChangeSet(DatabaseQueryMechanism.java:251)
         at oracle.toplink.queryframework.WriteObjectQuery.executeDatabaseQuery(WriteObjectQuery.java:47)
         at oracle.toplink.queryframework.DatabaseQuery.execute(DatabaseQuery.java:620)
         at oracle.toplink.queryframework.DatabaseQuery.executeInUnitOfWork(DatabaseQuery.java:542)
         at oracle.toplink.queryframework.ObjectLevelModifyQuery.executeInUnitOfWorkObjectLevelModifyQuery(ObjectLevelModifyQuery.java:100)
         at oracle.toplink.queryframework.ObjectLevelModifyQuery.executeInUnitOfWork(ObjectLevelModifyQuery.java:72)
         at oracle.toplink.publicinterface.UnitOfWork.internalExecuteQuery(UnitOfWork.java:2578)
         at oracle.toplink.publicinterface.Session.executeQuery(Session.java:988)
         at oracle.toplink.publicinterface.Session.executeQuery(Session.java:945)
         at oracle.toplink.internal.sessions.CommitManager.commitNewObjectsForClassWithChangeSet(CommitManager.java:243)
         at oracle.toplink.internal.sessions.CommitManager.commitAllObjectsForClassWithChangeSet(CommitManager.java:218)
         at oracle.toplink.internal.sessions.CommitManager.commitAllObjectsWithChangeSet(CommitManager.java:174)
         at oracle.toplink.publicinterface.Session.writeAllObjectsWithChangeSet(Session.java:3177)
         at oracle.toplink.publicinterface.UnitOfWork.commitToDatabase(UnitOfWork.java:1282)
         at oracle.toplink.publicinterface.UnitOfWork.commitToDatabaseWithChangeSet(UnitOfWork.java:1370)
         at oracle.toplink.publicinterface.UnitOfWork.commitRootUnitOfWork(UnitOfWork.java:1137)
         at oracle.toplink.publicinterface.UnitOfWork.commit(UnitOfWork.java:905)
         at com.tbs.database.DBBroker.mergeSingleObject(DBBroker.java:288)
         at com.tbs.database.DBBroker.merge(DBBroker.java:235)
         at com.tbs.database.DBBrokerSetInvoker.merge(DBBrokerSetInvoker.java:73)
         at com.tbs.database.TbsDataSource.merge(TbsDataSource.java:353)
    /////////////////////////////////

  • Invalid_path exception while using UTL_FILE.FOPEN

    Hi
    I am getting invalid_path exception while using the UTL_FILE.fopen subprogram. I tried finding out the reason but could not solve it. Please help.
    Below is my piece of code.
    create directory utldr as 'e:\utldir';
    declare
    f utl_file.file_type;
    s varchar2(200);
    begin
    dbms_output.put_line('1');
    f := utl_file.fopen('UTLDR','utlfil.txt','r');
    dbms_output.put_line('2');
    utl_file.get_line(f,s);
    dbms_output.put_line('3');
    utl_file.fclose(f);
    dbms_output.put_line('4');
    dbms_output.put_line(s);
    exception
    when utl_file.invalid_path then
    dbms_output.put_line('invalid_path');
    end;
    the result is:
    1
    invalid_path

    I am executing it from sys. The same user who created the directory.
    The output is as below:
    SELECT * FROM dba_directories
    OWNER     DIRECTORY_NAME     DIRECTORY_PATH
    SYS     MEDIA_DIR      d:\avale\rel4\demo\schema\product_media\
    SYS     LOG_FILE_DIR     d:\avale\rel4\assistants\dbca\logs\
    SYS     DATA_FILE_DIR     d:\avale\rel4\demo\schema\sales_history\
    SYS     EMP_DIR     E:\Oracle Directory
    SYS     REMOTED     \\10.1.1.12\oracle directory
    SYS     UTLDR     e:\utldir
    SELECT * FROM dba_tab_privs WHERE table_name='UTLDR'
    GRANTEE     OWNER     TABLE_NAME     GRANTOR     PRIVILEGE     GRANTABLE     HIERARCHY
    PUBLIC     SYS     UTLDR     SYS     READ     NO     NO

  • I can not connect to the internet while using my ipad I get a message saying Safari could not open the page because the server stopped responding need help thank you

    I CAN NOT CONNECT TO THE INTERNET WHILE USING MY IPAD I KEEP GETTING A MESSAGE SAYING SAFARI COULD NOT OPEN THE PAGE BECAUSE THE SERVER STOPPED RESPONDING PLEASE HELP THANK YOU

    Try the following:
    1. Turn router off for 30 seconds and on again
    2. Settings>General>Reset>Reset Network Settings
    3. Reset iPad; hold the Sleep and Home button down until you see the Apple Logo

  • How to remove ":"  in file name while using Variable substution

    Hi ALL
    I am using  file adapter and I what to create file name dynamically by acesssing PO number and time stamp from the payload using variable substution.
    But the problem is I am getting ":" in time stamp field value and it is not acceptable for file name .
    So could you please tell me a way that I can remove this ":" from that particular field value and create the file name dynamically.
    Note 1)Add Time stamp option will not help me as we require a time stamp of particular zone.
    2) Dynamic Configuration code is also not use full as I am using 1:n file creation

    >
    Prasanna Kumar wrote:
    > Hi ALL
    >
    > I am using  file adapter and I what to create file name dynamically by acesssing PO number and time stamp from the payload using variable substution.
    > But the problem is I am getting ":" in time stamp field value and it is not acceptable for file name .
    > So could you please tell me a way that I can remove this ":" from that particular field value and create the file name dynamically.
    >
    > Note 1)Add Time stamp option will not help me as we require a time stamp of particular zone.
    > 2) Dynamic Configuration code is also not use full as I am using 1:n file creation
    does the time stamp with the ":" a part of your output file?
    else use a replaceAll function in your mapping and replace the : with empty string then use the value in the variable substitution
    Another option is use the normal BPM for 1: N message flow. The use a simple java mapping that will introduce a dynamic configuration and you can create the file name as you want. the java mapping will be used in the flow of messages from BPM to target system.
    ref: /people/shabarish.vijayakumar/blog/2009/03/26/dynamic-configuration-vs-variable-substitution--the-ultimate-battle-for-the-file-name

  • How to delete contents of a csv file except header using powershell

    Hi,
    I am trying to delete all the content of my csv file except its header. currently I am using clear-content but using this headers are also getting deleted. Basically I need a command which deletes all the rows of a csv file except first row.Please help.

    I'm only going to respond to prove that the useless troll is useless and wrong.
    Perhaps someday the troll will finally realize that it is worthless and will go away. No one cares about what it has to say and no one has ever found it to be helpful. Even good information is bad information when it is presented in an insulting, blathering,
    incoherent, and belittling tone. Plus, I think it's really funny when something tries to justify its own sad existence by making itself feel superior (when it clearly isn't). Sometimes I almost feel bad for it, but then it reminds me of how big of a jerk it
    really is.
    Get a life, get some friends, just go do something that isn't totally worthless (yeah, I know, you can't..).
    Don't retire TechNet! -
    (Don't give up yet - 12,700+ strong and growing)

  • Encountering ORA-39000: bad dump file specification while using datapump

    Hello,
    I am trying to use datapump to take a export of a schema(Meta_data only). However, I want the dump file to be named after the date & time of the export taken.
    When i use the following command -- the job runs perfectly.
    expdp system@***** dumpfile=expdp-`date '+%d%m%Y_%H%M%S'`.dmp directory=EXP_DP logfile=expdp-`date '+%d%m%Y_%H%M%S'`.log SCHEMAS=MARTMGR CONTENT=METADATA_ONLY
    However, I want to run the export using an parfile. but if use the below parfile, i am encountering the following errors.
    USERID=system@*****
    DIRECTORY=EXP_DP
    SCHEMAS=TEST
    dumpfile=expdp-`date '+%d%m%Y_%H%M%S'`
    LOGFILE=MARTMGR.log
    CONTENT=METADATA_ONLY
    expdp parfile=martmgr.par
    Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
    With the Partitioning option
    ORA-39001: invalid argument value
    ORA-39000: bad dump file specification
    ORA-39157: error appending extension to file "expdp-`date '+%d%m%Y_%H%M%S'`"
    ORA-07225: sldext: translation error, unable to expand file name.
    Additional information: 7217
    How do i append date&time to the dumpfile name when using a parfile.
    Thanks
    Rohit

    I got the below error while using the dumpfile parameter as dumpfile=dump_$export_date.dmp
    Export: Release 11.2.0.2.0 - Production on Thu Feb 7 16:46:22 2013
    Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
    Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
    With the Partitioning option
    ORA-39001: invalid argument value
    ORA-39000: bad dump file specification
    ORA-39157: error appending extension to file "dump_$export_date.dmp"
    ORA-07225: sldext: translation error, unable to expand file name.
    Additional information: 7217
    Script i used is as follows
    export ORACLE_HOME=/orcl01/app/oracle/product/11.2.0.2
    export ORACLE_SID=$1
    export PATH=$PATH:$ORACLE_HOME/bin
    echo $ORACLE_HOME
    export export_date=`date '+%d%m%Y_%H%M%S'`
    echo $export_date
    expdp parfile=$2
    parfile is
    DIRECTORY=EXP_DP
    SCHEMAS=MARTMGR
    dumpfile=dump_$export_date.dmp
    LOGFILE=MARTMGR.log
    CONTENT=METADATA_ONLY

  • Security Exception while using OIM client API with Webcenter

    Hi,
    We are using OIM 11g Client api for creating user from our WebCenter portal application. But we are getting security as well as no such service exception while calling login from the OIM client.
    Exception::
    oracle.iam.platform.utils.NoSuchServiceException: java.lang.reflect.InvocationTargetException
         at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:197)
         at oracle.iam.platform.OIMClient.getService(OIMClient.java:174)
         at oracle.iam.platform.OIMClient.loginSessionCreated(OIMClient.java:209)
         at oracle.iam.platform.OIMClient.login(OIMClient.java:136)
         at oracle.iam.platform.OIMClient.login(OIMClient.java:114)
    Caused by: java.lang.reflect.InvocationTargetException
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
         at oracle.iam.platform.OIMClient.getServiceDelegate(OIMClient.java:193)
    Caused by: java.lang.SecurityException: [Security:090398]Invalid Subject: principals=[weblogic, Administrators]
         at weblogic.rjvm.ResponseImpl.unmarshalReturn(ResponseImpl.java:234)
    oracle.iam.platform.utils.NoSuchServiceException: java.lang.reflect.InvocationTargetException
    Client Code::
    System.setProperty("java.security.auth.login.config", "Path to authwl.conf");
    System.setProperty("OIM.AppServerType", "weblogic");
    env = new Hashtable();
    env.put(OIMClient.JAVA_NAMING_FACTORY_INITIAL,"weblogic.jndi.WLInitialContextFactory");
    env.put(OIMClient.JAVA_NAMING_PROVIDER_URL, "t3://host:14000/oim");
    client = new OIMClient(env);
    try {
    client.login(OIMUserName, OIMPassword);
    } catch (LoginException e) {
    e.printStackTrace();
    The exception is coming after executing the login code (not login exception).We logged into our application using weblogic user(even for any other user in OID,shared by OIM, is having same behaviour). The code is being executed from integrated webogic server and oim_server is running on a different server under a separate domain.
    Please suggest.
    Thanks

    There are files needed in your project.
    from the <OIMHOME>/config folder_
    xl.policy
    authwl.conf
    log.properties
    from the <OIMHOME>/ext folder_
    commons-logging.jar
    jakarta-oro-2.0.8.jar
    javagroups-all.jar
    jhall.jar
    log4j-1.2.8.jar
    mail.jar
    oscache.jar
    spring.jar
    wlfullclient.jar
    from the <OIMHOME>/lib folder_
    iam-platform-auth-client.jar
    iam-platform-context.jar
    iam-platform-pluginframework.jar
    iam-platform-utils.jar
    oimclient.jar
    XellerateClient.jar
    xlAPI.jar
    xlDataObjectBeans.jar
    xlUtils.jar
    xlVO.jar

  • Exception while using Nested types in Oracle

    Hi All,
    I am getting an exception while trying to use Nested types in Oracle. The same thing works in other systems. So it might be some problem with my configuration. Can anyone please help me out with this one. Thanks in advance..
    java.sql.SQLException: Internal Error
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:146)
    at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:208)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.initCollElemTypeName(OracleTypeCOLLECTION.java:1074)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.getAttributeType(OracleTypeCOLLECTION.java:1107)
    at oracle.jdbc.oracore.OracleNamedType.getFullName(OracleNamedType.java:81)
    at oracle.jdbc.oracore.OracleNamedType.getFullName(OracleNamedType.java:68)
    at oracle.sql.TypeDescriptor.initSQLName(TypeDescriptor.java:237)
    at oracle.sql.TypeDescriptor.getName(TypeDescriptor.java:198)
    at oracle.sql.StructDescriptor.getClass(StructDescriptor.java:1105)
    at oracle.sql.STRUCT.toJdbc(STRUCT.java:574)
    at oracle.jdbc.oracore.OracleTypeUPT.unpickle81UPT(OracleTypeUPT.java:502)
    at oracle.jdbc.oracore.OracleTypeUPT.unpickle81rec(OracleTypeUPT.java:456)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81ImgBodyElements(OracleTypeCOLLECTION.java:1011)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81ImgBody(OracleTypeCOLLECTION.java:952)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81(OracleTypeCOLLECTION.java:764)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unlinearizeInternal(OracleTypeCOLLECTION.java:243)
    at oracle.jdbc.oracore.OracleTypeCOLLECTION.unlinearize(OracleTypeCOLLECTION.java:217)
    at oracle.sql.ArrayDescriptor.toJavaArray(ArrayDescriptor.java:891)
    at oracle.sql.ARRAY.getArray(ARRAY.java:315)
    at weblogic.jdbc.wrapper.Array_oracle_sql_ARRAY.getArray(Unknown Source)
    Regards,
    Praveen G S

    Ok .. i got around this issue myself ..
    For others who might have had to face the same problem, let me tell them the problem that i had... i ll b happy if it helps someone ...
    The issue was improper privleges of the Nested Types in the schema to which my server was connecting. Once proper privelges were given, everything started working just fine ...

  • Getting error in File adapter while using ChunkSize

    Hi,
    I am trying to move a large file using the ChunkSize property of the file adapter as shown below. However I am getting the error during the run time in the SOA server.
    Code used:
    <adapter-config name="SyncReadFile" adapter="File Adapter" wsdlLocation="SyncReadFile.wsdl" xmlns="http://platform.integration.oracle/blocks/adapter/fw/metadata">
      <connection-factory location="eis/FileAdapter"/>
      <endpoint-interaction portType="SynchRead_ptt" operation="SynchRead">
        <interaction-spec className="oracle.tip.adapter.file.outbound.FileIoInteractionSpec">
          <property name="DeleteFile" value="true"/>
          <property name="PhysicalDirectory" value="C:\JDeveloper\mywork\JCAPs\ChunkFileRead\Input"/>
          <property name="FileName" value="overwriteme.txt"/>
          <property name="ChunkSize" value="55"/>
        </interaction-spec>
      </endpoint-interaction>
    </adapter-config>
    Error:
    Exception occured when binding was invoked. Exception occured during invocation of JCA binding: "JCA Binding execute of Reference operation 'SynchRead' failed due to: Exception occured when binding was invoked. Exception occured during invocation of JCA binding: "Could not instantiate InteractionSpec oracle.tip.adapter.file.outbound.FileIoInteractionSpec due to: Cannot set JCA WSDL Property. Error while setting JCA WSDL Property. Property setChunkSize is not defined for oracle.tip.adapter.file.outbound.FileIoInteractionSpec Please verify the spelling of the property. ". The invoked JCA adapter raised a resource exception. Please examine the above error message carefully to determine a resolution. ". The invoked JCA adapter raised a resource exception. Please examine the above error message carefully to determine a resolution.
    Please suggest a resolution to this. I am using Jdeveloper 11.1.1.7.0

    Thank Daniel for the reply.
    But what is the impact user messaging service has here.  Can it happen that my oracle.tip.adapter.file.outbound.FileIoInteractionSpec is corrupted?
    Thanks
    Santanu

  • Receiver File Error while using Dynamic Configuration

    Hi All,
    My Scenario is from SAP IDOC --> PI --> FIle...
    In the mapping i have used the dynamic variable substitution for the receiver file....
    The Dyanamic file will be alwasy generated irrespective of the condition for the Mapping...
    Now Whenever SAP sends IDOC then file to be created . If the condition is met then there is no problem the file is being created...
    But if condition is not met then the error is being thrown in the Communication Channel...
    Error occurred while connecting to the FTP server "10.1.999.222:21": java.lang.Exception: Exception in XML Parser (format problem?):'java.lang.Exception: Message processing failed in XML parser: 'Conversion configuration error: Unknown structure '' found in document', probably configuration error in file adapter (XML parser error)'
    Note the payload has the dyanmic file generated....
    And when i tested the mapping by coping the payload then
    I am getting the target with empty ...but with MT_ProductMaster node...
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:MT_ProductMaster xmlns:ns0="http://xyz/Ix_ProductMaster/WMS"></ns0:MT_ProductMaster>
    and the error i think bcz of this payload ... but i dont have any option to remove this .... because if condition not met then the root node always will be created...
    In CC File  Content conversion i have given like this
    Record setStructure  FileHeader,FileDetail,FileTrailer
    FileHeader.fieldSeparator |
    FileHeader.endSeparator |'nl'
    FileDetail.fieldSeparator |
    FileDetail.endSeparator |'nl'
    FileTrailer.fieldSeparator |
    FileTrailer.endSeparator |
    and my MT structure is
    MT_ProductMaster 1.1
    FileHeader  0...1
    FileDetail 0....unbounded
    FileTrailer 0...1
    Please help me on how to ignore the empty root node... do i need to handle something else???
    Regards,
    Sridhar Reddy

    Hey
    Record setStructure FileHeader,FileDetail,FileTrailer
    FileHeader.fieldSeparator |
    FileHeader.endSeparator |'nl'
    FileDetail.fieldSeparator |
    FileDetail.endSeparator |'nl'
    FileTrailer.fieldSeparator |
    FileTrailer.endSeparator |
    and my MT structure is
    MT_ProductMaster 1.1
    FileHeader 0...1
    FileDetail 0....unbounded
    FileTrailer 0...1
    of course you will get error in content conversion if file is missing any of the parameters expected by FCC.
    Right now the Content conversion is expecting several values in your payload(even if blank values) but you don't have any of them hence you get this error.
    If you want to deliver empty file,you need to map all the receiver side nodes to some default,so that it is populated to that default (could be blank) if no values are present,then when this comes to content conversion,it will assume the blank value as node and do correct conversion.
    If you dont have values in payload but have specified parameters for it on content conversion,then you will get errors as you mentioned in your first post.
    Thanks
    Aamir

  • "Cannot interpret data in file" error while using GUI_UPLOAD for .xls file

    Hi,
         I have made a program using FM GUI_UPLOAD to upload an .xls file to an internal table. But upon executing ,it gives error "Cannot Interpret data in file". I have seen in other posts people talking about GUI_UPLOAD FM to upload data from excel directly into internal table. Kindly help.
    Here is my code. I had tried using different combination for HAS_FIELD_SEPARATOR but still its not working.
    In my emp1.xls file , the data in each column is present in the same order as in the internal table. Although the first column in my internal table is NUMC. I dont know if that is causing the problem.
    REPORT  ZUPLOAD_1.
    data: itab TYPE TABLE OF zempl_master WITH HEADER LINE.
    CALL FUNCTION 'GUI_UPLOAD'
      EXPORTING
        FILENAME                      = 'C:\empl1.xls'
        FILETYPE                      = 'ASC'
        HAS_FIELD_SEPARATOR           = 'X'
    *   HEADER_LENGTH                 = 0
    *   READ_BY_LINE                  = 'X'
    *   DAT_MODE                      = ' '
    *   CODEPAGE                      = ' '
    *   IGNORE_CERR                   = ABAP_TRUE
    *   REPLACEMENT                   = '#'
    *   CHECK_BOM                     = ' '
    *   VIRUS_SCAN_PROFILE            =
    *   NO_AUTH_CHECK                 = ' '
    * IMPORTING
    *   FILELENGTH                    =
    *   HEADER                        =
      TABLES
        DATA_TAB                      = itab.
    * EXCEPTIONS
    *   FILE_OPEN_ERROR               = 1
    *   FILE_READ_ERROR               = 2
    *   NO_BATCH                      = 3
    *   GUI_REFUSE_FILETRANSFER       = 4
    *   INVALID_TYPE                  = 5
    *   NO_AUTHORITY                  = 6
    *   UNKNOWN_ERROR                 = 7
    *   BAD_DATA_FORMAT               = 8
    *   HEADER_NOT_ALLOWED            = 9
    *   SEPARATOR_NOT_ALLOWED         = 10
    *   HEADER_TOO_LONG               = 11
    *   UNKNOWN_DP_ERROR              = 12
    *   ACCESS_DENIED                 = 13
    *   DP_OUT_OF_MEMORY              = 14
    *   DISK_FULL                     = 15
    *   DP_TIMEOUT                    = 16
    *   OTHERS                        = 17
    IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    LOOP at itab.
      write:/ itab-emp_no,itab-name.
    endloop.

    hi amber22 you need to use the below fm to upload an xls file
    FORM EXCEL_UPLOAD .
    CALL FUNCTION 'ALSM_EXCEL_TO_INTERNAL_TABLE'
        EXPORTING
          FILENAME    = FILENAM
          I_BEGIN_COL = 1
          I_BEGIN_ROW = 1
          I_END_COL   = 6
          I_END_ROW   = 100
        TABLES
          INTERN      = xl_itab.
    * EXCEPTIONS
    * INCONSISTENT_PARAMETERS = 1
    * UPLOAD_OLE = 2
    * OTHERS = 3 .
      IF SY-SUBRC = 0.
    MESSAGE 'DATA UPLOADED SUCCESSFULLY' TYPE 'I'.
      ENDIF.
    ENDFORM.                    " EXCEL_UPLOAD

  • Huge file size while using smart objects?

    I'm laying out some big panels containing smaller images, so I am adding these using 'File>Place'. However, while the empty panel takes up about 70 MB, placing 3MB worth of smaller images makes the file size explode to a whopping 150MB, making it impossible to fill up the entire board. So far, I've seen file sizes of 500 MB, with Photoshop eating up 50GB swap files. Any idea what is going on here?
    (I'm using Photoshop CS4 on OS X 10.7.3)

    If you are familiar with Indesign and Illustrators and how they handle placed images that can lead to expectations that are not met by Photoshop’s Smart Objects.
    But the Smart Object-approach in Photoshop offers other advantages – there is no need to collect the linked images when handing on a file, because they are part of the document.
    You may want to check out:
    http://feedback.photoshop.com/photoshop_family/topics/please_consider_a_references_tool_to _create_links_to_layers_or_folder_groups

  • FormTemplate not found Exception while using adobe Services

    Hi,
    We are trying to create a pdf file using Adobe Services from webDynpro.
    However, in doing so, we get an error saying-
    "The error is:
    com.sap.tc.webdynpro.services.exceptions.WDRuntimeException:
    FormTemplate was not found"
    Followed by the message-
    java.io.FileNotFoundException: ./temp/webdynpro/public/asianpaints.com/login_form_using_adobe/webdynpro/Components/com.apl.test.login_form_using_adobe.LoginForm/PdfForm_InteractiveForm.xdp (No such file or directory
    (errno:2))
    at java.io.FileInputStream.open(Native Method)
    at java.io.FileInputStream.<init>(FileInputStream.java:106)
    at
    com.sap.tc.webdynpro.clientserver.adobe.AdobeFormHelper.getTemplateURL
    (AdobeFormHelper.java:659)
    However, the PdfForm_InteractiveForm.xdp (template Source) file exists
    in the specified position.We are using Adobe Reader 6.0 on NWD04
    Could you please let us know the solution to this problem at the
    earliest as we are in the midst of the development.
    Thanks in advance
    Apeksha

    Hi,
    Thanks for the reply. I worked recreated the application by simple reinserting the interactive UI element and binding its dataSource context with a node whose values i need to display in the pdf format and pdfsource bound to attibute of type binary. However, when i deploy, i get the following exception:
    Processing HTTP request to servlet [dispatcher] finished with error.
    The error is: com.sap.tc.webdynpro.services.exceptions.WDRuntimeException: Error during call to AdobeDocumentServer: Failed to create a Data Manager. Please ensure that the Document Services Data Manager service is running:
    com.adobe.FailedCreationException
    Exception id: [001083FE64E6006900000218000010E80004194FC07D8B75]
    However, the Document Services Data Manager service is already running along with IIOP provider.Are there some other things that need to be taken care of?
    Thanks in Advance
    Apeksha

Maybe you are looking for