Adding a JSP page to an application

Hi,
I want to add a JSP page called image.jsp to an oc4j service called analytics. I probably have to change something in the web.xml, but keep running into: 500 Internal Server Error
Servlet error: An exception occurred. The current application deployment descriptors do not allow for including it in this response.
my web.xml now looks like this:
<?xml version="1.0"; encoding="UTF-8"?>
<!DOCTYPE web-app
     PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN";
     "http://java.sun.com/dtd/web-app_2_3.dtd";>
<web-app>
     <servlet>
          <servlet-name>SAWBridge</servlet-name>
          <servlet-class>com.siebel.analytics.web.SAWBridge<;/servlet-class>
          <init-param>
               <param-name>oracle.bi.presentation.sawserver.Host<;/param-name>
               <param-value>localhost</param-value>
          </init-param>
          <init-param>
               <param-name>oracle.bi.presentation.sawserver.Port<;/param-name>
               <param-value>9710</param-value>
          </init-param>
     </servlet>
     <servlet-mapping>
          <servlet-name>SAWBridge</servlet-name>
          <url-pattern>/saw.dll<;/url-pattern>
     </servlet-mapping>
     <servlet>
          <servlet-name>image</servlet-name>
          <servlet-class>/image</servlet-class>
     </servlet>
     <servlet-mapping>
          <servlet-name>image</servlet-name>
          <url-pattern>/image</url-pattern>
     </servlet-mapping>
     <mime-mapping>
          <extension>xsd</extension>
          <mime-type>text/xml</mime-type>
     </mime-mapping>
     <welcome-file-list>
          <welcome-file>default.jsp<;/welcome-file>
          <welcome-file>image.jsp<;/welcome-file>
     </welcome-file-list>
</web-app>
any pointers are much appreciated.
I'm a total newbie with configuring OC4J...
Regards
John
EDIT: error log:
java.lang.NullPointerException
     at image.jspService(_image.java:90)
     [SRC:/image.jsp:44]
     at com.orionserver[Oracle Containers for J2EE 10g (10.1.3.1.0) ].http.OrionHttpJspPage.service(OrionHttpJspPage.java:59)
     at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:453)
     at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:591)
     at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:515)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
     at com.evermind[Oracle Containers for J2EE 10g (10.1.3.1.0) ].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:711)
     at com.evermind[Oracle Containers for J2EE 10g (10.1.3.1.0) ].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:368)
     at com.evermind[Oracle Containers for J2EE 10g (10.1.3.1.0) ].server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:866)
     at com.evermind[Oracle Containers for J2EE 10g (10.1.3.1.0) ].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:448)
     at com.evermind[Oracle Containers for J2EE 10g (10.1.3.1.0) ].server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:216)
     at com.evermind[Oracle Containers for J2EE 10g (10.1.3.1.0) ].server.http.HttpRequestHandler.run(HttpRequestHandler.java:117)
     at com.evermind[Oracle Containers for J2EE 10g (10.1.3.1.0) ].server.http.HttpRequestHandler.run(HttpRequestHandler.java:110)
     at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
     at com.evermind[Oracle Containers for J2EE 10g (10.1.3.1.0) ].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
     at java.lang.Thread.run(Thread.java:619)
maybe something else?
Edited by: John Minkjan on Sep 18, 2009 1:34 AM

hi John
There does seem to be a problem on line 44 of your image.jsp page:
java.lang.NullPointerException
at _image._jspService(_image.java:90)
SRC:/image.jsp:44
...Would you mind posting a part of your image.jsp page that includes line 44 (or the complete page if it is not too big)?
You wrote "... I probably have to change something in the web.xml, ...", why do you think that is the case?
regards
Jan Vervecken

Similar Messages

  • Adding my jsp page for administration

    can i attach my jsp page to manage users and groups by admin, instead of 9IAS portal page to manage users and groups. if i can use it , then how can i map the values entered in my jsp page with the 9IAS portal page for creating and managing users and groups.

    Then your question was wrong. You asked how to include package. The solution to that is that you don't need to add the import since it happens automatically.
    Your actual problem was that the package was not found. If you'd mentioned that earlier, someone could've suggested that you check to see if you'd added the API library to your classpath and you'd have got your answer faster.
    You should state your exact problem and post the relevant stack trace and exceptions and code if any.
    People on the forum help others voluntarily, it's not their job.
    Help them help you.
    Learn how to ask questions first: http://faq.javaranch.com/java/HowToAskQuestionsOnJavaRanch
    ----------------------------------------------------------------

  • How to forward a jsp page in flex application ( when a button is clicked)

    i am a fresher to this FLEX 2.0 , i designed the UI part in
    flex, but when i click the submit button it has to forward to the
    JSP page to check against the valid user,password , so how to
    forward the page to jsp(i mean from flex to jsp) , if u can suggest
    me with an example, it will be easy for me, is Flex Data Service 2
    is necessary for this
    thanks for ur speedy reply, hopping to get the solution for
    this issue,
    sandeep

    Your JSP is, as far as Flex is concerned, just a data service
    which it will request and read its response. I'd suggest using
    <mx:HTTPService>. For example:
    <mx:HTTPService id="authorize" url="validate.jsp"
    fault="handleFault(event)" result="handleResult(event)">
    <mx:request>
    <userid>{username.text}</userid>
    <password>{password.text}</password>
    </mx:request>
    </mx:HTTPService>
    Flex creates the request:
    http://{server}.{port}{context.root}/validate.jsp?userid=fred&password=flintstone
    assuming that you have <mx:TextInput id="username" />
    and <mx:TextInput id="password" /> components.
    Your Submit button then does: authorize.send()
    (note: you can also pass the request parameters in the send()
    method - check the Flex docs on HTTPService).
    Flex will listen for the response from your JSP. Typically a
    JSP would respond with an HTML page, but you don't want to do that
    for Flex. Your JSP should produce either a simple string ("yes" or
    "no" or "error" etc) or an XML document.
    The handleResult method can examine the response and do
    what's necessary.

  • Can't us Oracle API on the simple JSP pages added to the portlet........

    Hi,
    I added a jsp page in the portlet which is not a standard page like the default show mode pages. I have added some code which actually access a resource inside the porltet.
    " img src="<%= UrlUtils.constructResourceURL (pReq, HttpPortletRendererUtil .absoluteLink(request, "icon.png")) %> "
    For that you have to add the following two imports in the code
    mport="oracle.portal.provider.v2.render.http.HttpPortletRendererUtil"
    import="oracle.portal.provider.v2.url.UrlUtils"
    This library is available with the JDeveloper and I dont get any error while compiling and even deploying the portlet war file on the applcation server. Strangely the same piece of code shows the image perfectly for the default show page of the portlet but it generates 500 Internal server error for the other simple jsp page I added, which suggests that the server is unable to find the function:
    500 Internal Server Error
    java.lang.NullPointerException
         at oracle.portal.provider.v2.url.UrlUtils.constructResourceURL(Unknown Source)
         at _htdocs._elogbooksubsystems._DAQ._jspService(_DAQ.java:54)
         [SRC:/htdocs/elogbooksubsystems/DAQ.jsp:15]
         at com.orionserver[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].http.OrionHttpJspPage.service(OrionHttpJspPage.java:56)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:350)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:509)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:413)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:824)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:330)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:830)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:285)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:126)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
         at java.lang.Thread.run(Thread.java:534)
    Can anybody help? Is this possible to use oracle api in the pages which are though added to the portlet but not the standard show modes pages?
    Thanking you in anticipation
    Regards,
    Omer Alvi
    Message was edited by:
    user574208
    Message was edited by:
    user574208

    Thanks Nrintala. I tried to work with multipage portlet example provided in the jpdk. In fact I created another portlet with two pages and copied the code of the two pages of the multipage portlet. (Off course I took care of the names and stuff). Later I modified the provider.xml by defining "next_page" parameter. When I viewed my portlet, first page appeared fine but when I click on the link which should show the second page, I got an error which says.
    Error:      Error occurred while rendering portlet - see provider log file for details.
    Do you think I have missed something? I am depoying my war file on the stand alone OC4J and some how I have not been able to find the application.log file in my application inside the application_deployments of the J2EE_HOME. I have pasted the provider.xml file and I would be grateful if you can help.
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <?providerDefinition version="3.1"?>
    <provider class="oracle.portal.provider.v2.DefaultProviderDefinition">
    <session>false</session>
    <passAllUrlParams>true</passAllUrlParams>
    <portlet class="oracle.portal.provider.v2.DefaultPortletDefinition">
    <id>1</id>
    <name>mulitpage</name>
    <title>testing multi page</title>
    <description>My Portlet Description</description>
    <timeout>40</timeout>
    <showEditToPublic>false</showEditToPublic>
    <hasAbout>false</hasAbout>
    <showEdit>false</showEdit>
    <hasHelp>false</hasHelp>
    <showEditDefault>false</showEditDefault>
    <showDetails>false</showDetails>
    <renderer class="oracle.portal.provider.v2.render.RenderManager">
    <contentType>text/html</contentType>
    <showPage>/htdocs/mulitpage/first.jsp</showPage>
    <pageParameterName>next_page</pageParameterName>
    </renderer>
    </portlet>
    </provider>
    Best regards,
    Omer
    Message was edited by:
    user574208
    Message was edited by:
    user574208

  • How to retrieve multiple data from table and represent it in jsp page

    Hi
    The below JavaScript code is used to add row in the table when I want to add multiple row data into table for single entry no field.
      <html>  function addRow()
                i++;
                var newRow = document.all("tblGrid").insertRow();
                var oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='srno"+i+"' type='text' id='srno"+i+"' size=10>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='itmcd"+i+"' type='text' id='itmcd"+i+"' size='10'>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='itmnm"+i+"' type='text' id='itmnm"+i+"' size='15'>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='indentqty"+i+"' type='text' id='indentqty"+i+"' size='10'>";
                oCell = newRow.insertCell();
                    oCell.innerHTML = "<input name='uom"+i+"' type='text' id='uom"+i+"' size='10'><input type='hidden' name='mcode"+i+"'id='mcode"+i+"'>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='packqty"+i+"' type='text' id='packqty"+i+"' size='10'>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='packuom"+i+"' type='text' id='packuom"+i+"' size='10'><input type='hidden' name='pack"+i+"' id='pack"+i+"'>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='rate"+i+"' type='text' id='rate"+i+"' size='10'>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='dor"+i+"' type='text' id='dor"+i+"' size='0' onClick='"+putdate(this.name)+"'>";           
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='bccode"+i+"' type='text' id='bccode"+i+"' size='10'></td><input type='hidden' name='bcc"+i+"' id='bcc"+i+"'>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='cccode"+i+"' type='text' id='cccode"+i+"' size='10'></td><input type='hidden' name='ccc"+i+"' id='ccc"+i+"'>";
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input name='remark2"+i+"' type='text' id='remark2"+i+"' size='20'>";           
                oCell = newRow.insertCell();
                oCell.innerHTML = "<input type='button' value='Delete' onclick='removeRow(this);' />";
               // oCell = newRow.insertCell();
               // oCell.innerHTML = "<input type='button' value='Clear' onclick='clearRow(this);' />";
            }<html>  Then this data are send to the next Servlet for adding into two table.
    My header portion data are added into one table which added only one row in table. while footer section data are added into the no of rows in another table dependent on No. of
    Rows added into jsp page.
    Here is an code for that logic.
    <html>
    ArrayList<String> mucode = new ArrayList<String>();
                                ArrayList<Integer> serials = new ArrayList<Integer>();
                                ArrayList<Integer> apxrate = new ArrayList<Integer>();
                                ArrayList<Integer> srname = new ArrayList<Integer>();
                                ArrayList<String> itcode = new ArrayList<String>();
                                ArrayList<String> itname = new ArrayList<String>();
                                ArrayList<Integer> iqnty = new ArrayList<Integer>();
                                ArrayList<String> iuom = new ArrayList<String>();
                                ArrayList<Integer> pqnty = new ArrayList<Integer>();
                                ArrayList<String> puom1 = new ArrayList<String>();
                               ArrayList<Integer> arate = new ArrayList<Integer>();
                                ArrayList<String> rdate = new ArrayList<String>();
                                ArrayList<String> bcs = new ArrayList<String>();
                                ArrayList<String> ccs = new ArrayList<String>();
                                ArrayList<String> remarkss = new ArrayList<String>();
                                //ArrayList<Integer> qtyrecs = new ArrayList<Integer>();
                                //ArrayList<String> dors = new ArrayList<String>();
                                //ArrayList<String> remarks = new ArrayList<String>();
                     String entryn = request.getParameter("entryno");       
                        String rows = request.getParameter("rows");
                        out.println(rows);  
                        //String Entryno = request.getParameter("entryno");
                       // out.println(Entryno);
                      int entryno = 0,reqqty = 0,srno = 0,deprequest = 0,rowcount = 0;
                                if(!Entryno.equals("")){
                                        entryno = Integer.valueOf(Entryno);
                                if(!rows.equals("")){
                                        rowcount = Integer.valueOf(rows);
                               for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("srno"+i)!=null){
                                                serials.add(Integer.valueOf(request.getParameter("srno"+i).trim()));
                                                out.println(serials.size());
                                for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("srno"+i)!=null){
                                                srname.add(Integer.valueOf(request.getParameter("srno"+i).trim()));
                                out.println(srname.get(0));
                                for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("itmcd"+i)!=null){
                                                itcode.add(request.getParameter("itmcd"+i).trim());
                                        } //out.println(itcode.get(i));
                                for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("itmnm"+i)!=null){
                                                itname.add(request.getParameter("itmnm"+i).trim());
                                        }//out.println(itname.get(i));
                                for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("indentqty"+i)!=null){
                                                iqnty.add(Integer.valueOf(request.getParameter("indentqty"+i).trim()));
                                for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("uom"+i)!=null){
                                                iuom.add(request.getParameter("uom"+i).trim());
                                        }//out.println(iuom.get(i));
                                for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("mcode"+i)!=null){
                                                mucode.add(request.getParameter("mcode"+i).trim());
                               for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("packqty"+i).equals("")){
                                          pqnty.add(0);
                                        }else
                                            pqnty.add(Integer.valueOf(request.getParameter("packqty"+i).trim()));
                                for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("pack"+i)!=null){
                                                puom1.add(request.getParameter("pack"+i).trim());
                                       }else
                                        puom1.add("");
                               for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("rate"+i).equals("")){                                     
                                            arate.add(0);
                                        }else
                                        arate.add(Integer.valueOf(request.getParameter("rate"+i).trim()));   
                     /* for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("rate"+i)!=null){
                                                arate.add(Integer.valueOf(request.getParameter("rate"+i).trim()));
                              for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("dor"+i)!=null){
                                                try{
                                                        rdate.add(dashdate.format(slashdate.parse(request.getParameter("dor"+i).trim())));
                                                }catch(ParseException p){p.printStackTrace();}
                                        }else
                                           { rdate.add("");}
                                   for(int i=1;i<=rowcount;i++){
                                 if(request.getParameter("bcc"+i)!=null){
                                                bcs.add(request.getParameter("bcc"+i).trim());
                                        }out.println(bcs.get(0));
                                for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("ccc"+i)!=null){
                                                ccs.add(request.getParameter("ccc"+i).trim());
                                        }out.println(ccs.get(0));
                                for(int i=1;i<=rowcount;i++){
                                    out.println("remark2");
                                        if(request.getParameter("remark2"+i)!=null){
                                                remarkss.add(request.getParameter("remark2"+i).trim());
                                        }out.println(remarkss.get(0));
                        ArrayList<String> Idate = new ArrayList<String>();
                        for(int i=1;i<=rowcount;i++){
                                        if(request.getParameter("dateindent"+i)!=null){
                                                try{
                                                        Idate.add(dashdate.format(dashdate.parse(request.getParameter("dateindent"+i).trim())));
                                                }catch(ParseException p){p.printStackTrace();}
                    String Rdate = dashdate.format(new java.util.Date());
                     String tdate = dashdate.format(new java.util.Date());    
                     // String Indentdate = dashdate.format(new java.util.Date());
                   //  String ApprovedT1 = dashdate.format(new java.util.Date());
                   //  String ApprovedT2 = dashdate.format(new java.util.Date());
                       // String ApprovedT1=" ";
                        //String ApprovedT2="";*/
                    String ApprovedT1= dashdate.format(new java.util.Date());
                   out.println (ApprovedT1);
                      String ApprovedT2=dashdate.format(new java.util.Date());
                       out.println(ApprovedT2);
                    String Indentdate=(dashdate.format(slashdate.parse(request.getParameter("dateindent").trim())));
                       out.println(Indentdate);
                        String Cocode ="BML001";  
                        out.println(Cocode);
                        String Deptcode = request.getParameter("dept1");
                        out.println(Deptcode);
                        String Empcode = request.getParameter("emp");
                        out.println(Empcode);
                        String Refno =request.getParameter("rtype"); 
                         out.println(Refno);
                        String Divcode = request.getParameter("todiv1");
                        out.println(Divcode);
                        String Usercode = "CIRIUS";    
                         String Whcode = request.getParameter("stor");
                        out.println(Whcode);
                        // String Itemgroupcode = request.getParameter("");
                         String Itemgroupcode ="120000";
                         out.println(Itemgroupcode);
                        String Supplytypecode = request.getParameter("stype");
                        out.println(Supplytypecode);
                        String Delcode = request.getParameter("deliverycode");
                        out.println(Delcode);
                        String Itemclass="WS";
                        out.println(Itemclass);
                        // String Itemclass = request.getParameter("iclass");
                       // out.println(Itemclass);
                        String unitcode = request.getParameter("uni");
                        out.println(unitcode);
                         String Todivcode = request.getParameter("todiv1");
                        out.println(Todivcode);
                        String Appxrate = request.getParameter("rate");
                        out.println(Appxrate);
                        String Srno = request.getParameter("srno");
                        out.println(Srno);                
                    /*    String Indqty = request.getParameter("indentqty");
                      out.println(Indqty);*/
                  String Itemcode = request.getParameter("itmcd");
                       out.println(Itemcode);
                       String Othersp = request.getParameter("remark1");
                        out.println(Othersp);
                        String Reqdt = request.getParameter("dor");
                        out.println(Reqdt);
                        String Munitcode = request.getParameter("mcode");
                        out.println(Munitcode);
                        String Packqty = request.getParameter("packqty");
                        out.println(Packqty);               
                        String Packuom = request.getParameter("pack");
                        out.println(Packuom);
                        String Remark2 = request.getParameter("remark2");
                        out.println(Remark2);
                        String BC = request.getParameter("bcc");
                        out.println(BC);
                        String CC = request.getParameter("ccc");
                        out.println(CC);
                        try{
                            st=connection.createStatement();
                            connection.setAutoCommit(false);
                            String sql="INSERT INTO PTXNINDHDR(COCODE,DEPTCODE,EMPCODE,APPROVEDT1,APPROVEDT2,INDDT,ENTRYNO,REFNO,REMARKS,DIVCODE,USERCODE,WHCODE,ITEMGROUPCODE,SUPTYPECODE,DELCODE,UNITCODE,TODIVCODE,ITEMCLASS)VALUES('"+Cocode+"','"+Deptcode+"','"+Empcode+"','"+ApprovedT1+"','"+ApprovedT2+"','"+Indentdate+"',"+Entryno+",'"+Refno+"','"+Othersp+"','"+Divcode+"','"+Usercode+"','"+Whcode+"','"+Itemgroupcode+"','"+Supplytypecode+"','"+Delcode+"','"+unitcode+"','"+Todivcode+"','"+Itemclass+"')";
                            out.println(sql);
                            st.addBatch(sql);
                            for(int i=0;i<serials.size();i++){
                                out.println("Inside the Statement");
                                String query3="test query for u";
                                out.println(query3);
                               String queryx="Insert into PTXNINDDTL(APXRATE,ENTRYNO,BRKNO,INDQTY,ITEMCODE,OTHERSPFCS,MUNITCODE,PACKQTY,PACKUOM,REMARKS,DIMSUBGRPCODE,DIMCODE,REQDT)VALUES("+arate.get(i)+","+entryno+","+srname.get(i)+","+iqnty.get(i)+","+itcode.get(i)+",'"+Othersp+"','"+mucode.get(i)+"',"+pqnty.get(i)+",'"+puom1.get(i)+"','"+remarkss.get(i)+"','"+bcs.get(i)+"','"+ccs.get(i)+"','"+rdate.get(i)+"')";
                               out.println(queryx);
                                st.addBatch(queryx);
                           int[] result=st.executeBatch();
                           connection.commit();
                           for(int k=0;k<result.length;k++)
                           out.println("rows updated by "+(k+1)+"insert sta:"+result[k]+"");
                        catch(BatchUpdateException bue)
                        out.println("error1;"+bue+"");
                        catch(SQLException sql)
                        out.println("error2;"+sql+"");
                        catch(Exception l)
                        out.println("error3;"+l+"");
    </html>
       Now I looking for to retrieve this footer section data available in multiple rows from footer table and present it in jsp page .
    I am finding difficulties in how to show this multiple row data for dynamic no of rows .i.e. variable no. of rows.
    I have able to show the data in Header portions of page in this ways
    here i am adding the part of code which shows the data from header part of table i.e from Header table
      <html>
    <h2 align="center"><b>Indent Preparation</b></h2>
        <div align="left">
            <table width="849" border="0" cellspacing="3" cellpadding="3" align="center">
                <tr>
                    <td ><div align="left"><b>Indent No.</b></div></td>
                    <td ><label>
                            <input name="indentno" type="text" id="indentno" size="15" value="" /><input type="hidden" name="no" id="no">
                    </label></td>
                    <td ><div align="center"><strong>Indent Date</strong></div></td>
                    <td ><label>
                            <div align="center">
                                <input name="dateindent" type="text" id="dateindent"value="<%=date1%>"/><input type="hidden" name="no" id="no">
                            </div>
                    </label></td>
                    <td> </td>
                    <td><div align="right"><strong>Entry No.</strong></div></td>
                     <%if(oper!=null && oper.equals("view") && hdrcode!=null && hdrdetails!=null){%>
            <td><input type="text" value="<%=hdrcode.get(3)%>" size="10"></td>
    <%}else{%>
                   <td><input type="text" name="entryno" id="entryno" value="<%=entryNo%>"/></td>
                             <%}%>
                            <div align="right"></div>
                </tr>
                <tr>
                    <td><b>Division</b></td>
                    <%if(oper!=null && oper.equals("view") && hdrcode!=null && hdrdetails!=null){%>
    <td><input type="text" value="<%=hdrdetails.get(9)%>" size="20"</td>
    <td><input type="hidden" name="div1" id="div1" value='<%=hdrcode.get(10)%>'></td>
    <%}else{%>
                   <td><input type="text" name="div" id="div" /></td>
                   <td><input type="hidden" name="div1" id="div1" /> </td>
              <%}%>
                    <td> </td>
                    <td> </td>
                    <td><div align="right"><strong>Unit</strong></div></td>
                   <%if(oper!=null && oper.equals("view") && hdrcode!=null && hdrdetails!=null){%>
    <td><input type="text" value="<%=hdrdetails.get(14)%>" size="20"</td>
    <td><input type="hidden" name="uni" id="uni" value='<%=hdrcode.get(12)%>'></td>
    <%}else{%>
                   <td><input type="text" name="unit" id="unit" /></td>
                   <td><input type="hidden" name="uni" id="uni" /> </td>
              <%}%>
                </tr>
                <tr>
    </html>
      Any suggestion on any above works is highly appreciated.
    Thanks and regards
    harshal

    Too much code. It's also not well intented nor formatted. I don't see a question either or it got lost in that heap of unformatted code.
    I will only answer the question in the thread's subject:
    How to retrieve multiple data from table and represent it in jsp pageTo retrieve, make use of HttpServletRequest#getParameterValues() and/or #getParameter().
    To display, make use of JSTL's c:forEach.

  • How to call a concurrent program from a Custom JSP page.

    Hi,
    I have a custom JSP page which i have deployed by creating a form function with the path of the JSP Page
    and added the JSP Page to the OA_HTML top.
    Now, i need to call a concurrent program from the JSP Page, i have all the parameters in my page and i am using the standard class as below:
    ConcurrentRequest cr= new ConcurrentRequest(con);
    int requestId= cr.submitRequest("XXINV",programName,null,null,false,vec);
    I have verified my connection object and it is OK but i am getting the exception that user is not set to run the program.
    I tried the below code in my JSP page and getting -1 for all test variables :-
    int userId = wctx.getUserId();
    int respApplId = wctx.getRespApplId();
    int respId = wctx.getRespId();
    I think i need to set the context in JSP page to run the program..
    Pls help ....
    Regards
    Saurabh Jaiswal

    Hi,
    Thanks for the reply,,,
    This is a possible solution but this will allow to run the program anyhow.
    But the procedure which i call thru callable statement will start with
    fnd_global.apps_initialize (3825, 50603, 704);
    fnd_request.submit_request API call.
    Now, the values of user and Responsibilty is required in the program and it changes.
    With this approach we have to hardcode the user and resp.
    The same JSP page is attached to other responsibilities and there the concurrent program would get fired as if fired from the resp Id hardcoded as above.
    Need to capture user Id and RespId.
    How can i set the apps Context in JSP page???
    Regards
    Saurabh Jaiswal

  • How can I send email from an JSP page  with HTML format either using jsp

    hi,
    I have an jsp page with online application form,after compleating the form if i select submit it will send all the compleated data to the mail id we mentioned in the form tag,for this i am using javascript,but instead of receiving the data in the format of strings,my client want to receive the data in the same format as he's filling in the jsp page(html format) through e-mail.any help would be appreciated.the fallowing is the code right now i am using for email application.
    <code>
    function send()
    if(validatePersonalInfo(document.theform))
         document.theform.submit()
         location.href=location.reload()
    function validatePersonalInfo(form)
         var tmpStr ="";
         if (form.Name.value == "") {
              tmpStr = "Name";
              document.all.dName.style.visibility="visible";
              document.theform.Name.focus();
         else{
              document.all.dName.style.visibility="hidden";
         if (form.SSN.value == "") {
              tmpStr = tmpStr + ", Social Security Number";
         document.all.dSSN.style.visibility="visible";
         if(form.Name.value != "")
              {document.theform.SSN.focus();}
         else{
              document.all.dSSN.style.visibility="hidden";
    if (tmpStr == "") {
              return true;
         } else {
              alert("Please Fill the Following Fields: " + tmpStr);
              return false;
    <FORM NAME="theform" METHOD="post"
    ACTION="mailto:[email protected]?subject=Online Application Form for MinorityDealer." ENCTYPE="text/plain">
    <TABLE WIDTH="100%" BORDER="0" CELLSPACING="0" CELLPADDING="10" NOF="LY">
    <TH>
    <P>
         <FONT SIZE="3" FACE="Arial,Helvetica,Univers,Zurich BT">Online�Application</font></TH><BR>
    </TABLE>
    <table width="718" border="1" cellspacing="0" cellpadding="3" bgcolor="#CCCCFF" align="center">
         <tr>
    <td colspan="2"><font class="captionText">Name*�</font><br><input type="text" size="25" name="Name" class="bodyText">
    <div id="dName" name="dName" style="position:absolute;visibility:hidden"><font color="red">Name is Mandatory*</font></div>
    </td>
              <td colspan="2"><font class="captionText">Social Security Number*�</font><br><input type="text" size="9" name="SSN" class="bodyText">
              <div id="dSSN" name="dSSN" style="position:absolute;visibility:hidden"><font color="red">SSN is Mandatory*</font></div></td>
    </tr>
    <tr>
    <td colspan="2"><font class="captionText">Total Personal Assets</font><br><input type="text" size="10" name="TotPersAss3" class="bodyText"></td>
              <td colspan="2"><font class="captionText">Total Personal Liabilities & NetWorth</font><br><input type="text" size="10" name="TotPerLiab3" class="bodyText"></td>
    </tr>
         </tr>
    </TABLE>
    <IMG Valign="middle" name="imgSubmit" src="images/buttons/Submit.gif" width="66" height="29" border="0" alt="Submit">
    </code>

    Can any one do some help to solve this problem.
    Regards.

  • JSP page doesnt load for one user on machine1, but does 4 all on same box

    Hi,
    I have a Citrix application on a box to enable many users to connect remotely to different applications on differnt boxes using the browser on this box. Just like terminal Services or remote desktop
    I tested 15 users and all of them are able to login to the machine and able to open a jsp page of an application located on a differernt box using the browser on this box.
    But for one user I am facing an issue. For this user, I am not able to get the page and instead I only see a message as "page loading" and nothing more than that, Its getting stuck there itself with no progress.
    Please help me,
    Thanks a lot in advance,
    Srinivas.

    Hi,
    I suspect there is something missing as far as the JRE for this guy is concerned. Sothing to do with permissions. java policy, security etc.
    I am not sure if that helps. I am not in the development of the application, and will check with those guys. I only neeed to provode support on this machine and be able to give access to that application which is on Linux. The browser is in Windows machine,
    Thanks,
    Srinivas.

  • Need help on sharing a jsp page between clients?

    Hi,
    Let me explain this:
    In my jsp application I have two jsp pages that work as a find dialog like applet find dialog.One of those shows the columns from rowset(which user can enter the criteria ) and the other gets the values from first one, makes the sql query and execute the query against the rowset and retrieve the data. There is no pure servlet, both are jsp pages.
    This application is deployed on AS9i-oc4j.
    Problem is : When this find dialog is working for a client. The other client could not load this find dialog until the work for the first one be done. I mean only one client could load and fire the sql statement via this jsp pages(find dialog) at the same time. Which is not acceptable in web applications. Seems only one instance of these pages created by oc4j . if I am right on this then
    Question is : Why oc4j doesn’t create the number of instances based on the number of clients that call these pages? Did I miss something. Or any property in Application module need to be set?
    I would appreciate to share me your idea on this.
    Thanks.

    In my primary mind maybe the bottleneck is where the execution of rowset happens. Since that portion of code takes time to retrieve data for business components. If this is the case then Is this problem goes away if I define a thread for this portion of code?
    Thanks in advance for any idea.

  • Passing values to the JSP page - Urgent

    Hi all,
    I have to pass the user id value to the JSP page. I have written the following code in the doInitialization() method
    IPortalComponentRequest request = (IPortalComponentRequest) this.getRequest();
    IPortalComponentContext myContext = request.getComponentContext();
    IPortalComponentProfile myProfile = myContext.getProfile();
    IAuthentication ia = UMFactory.getAuthenticator();
    IUser portalUser = ia.getLoggedInUser(request.getServletRequest(), request.getServletResponse(false) );
    s = portalUser.getUniqueName();
    IPortalComponentSession componentSession = ((IPortalComponentRequest)getRequest()).getComponentSession();
    Object o = componentSession.getValue("myEvents");
    myEvents = (LoadEvents)o;
    //myEvents = (LoadEvents) myContext.getValue("myEvents");
    myEvents.setUserId(s);
    myContext.putValue("myBeanName", myEvents);
    I have also defined myEvents as a bean in my JSP page with scope APPLICATION. But I get User Id as "NULL".
    Thanks in advance.
    Rgds,
    Janvi.

    Hi Prakash,
    Please find the jsp code pasted below:
    <hbj:content
        id="myContext">
        <hbj:page
            title="Successful processing">
    <jsp:useBean id="myMeet" scope="application" class="com.sap.ep.bluestar.LoadEvents" />
    <jsp:useBean id="myEvents" class="com.sap.ep.bluestar.MonthView" scope="application" />
    <%@ page contentType="text/html; charset=iso-8859-1" language="java" import="java.sql.*" %>
    <%
    int leadSpaces, daysInMonth, leadSpaces_next,daysInMonth_next, col_Counter;
    myCal.setMonthView();
    java.util.Vector printVal_pre = new java.util.Vector();
    myCal.printMonth(myCal.getPre_month(),myCal.getPre_year());
    printVal_pre = myCal.getPrintValues();
    java.util.Vector printVal_cur = new java.util.Vector();
    myCal.printMonth(myCal.getCur_month(),myCal.getCur_year());
    printVal_cur = myCal.getPrintValues();
    java.util.Vector printVal_next = new java.util.Vector();
    myCal.printMonth(myCal.getNext_month(),myCal.getNext_year());
    printVal_next = myCal.getPrintValues();
    if(request.getMethod().equals("POST")){
         try {
              String action =(String) request.getParameter("action");
              if(action.equals("insert")){
              //     response.sendRedirect("_insertEvent.jsp");
                   //response.sendRedirect("test.html");
         } catch(Exception e) {
              System.out.println(e.getMessage());
    %>
    <!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=iso-8859-1">
    <title>Untitled Document</title>
    <script language="javascript">
         function insertEvent(frm,eventDay){
              alert("here finally " + eventDay + " " + frm.eventMonth.value + "  " + frm.eventYear.value );
              frm.action.value = "insert";
              frm.submit();
         function openWin(frm,eventDay)
           var newWin = window.open("http://localhost:50100/irj/servlet/prt/portal/prtroot/Web_Calendar.eventHandler?variable=" + frm.eventMonth.value +  "/" + eventDay + "/" + frm.eventYear.value, 'popup',
         'resizable,height=200,width=325');
           if(newWin.focus) newWin.focus();
    </script>
    </head>
    <body>
    User is : <%= myCal.getUserId() %>
    <table width="745" height="583" border="0">
      <tr>
        <td width="258" height="23" align="center"><B> <% out.println(printVal_pre.elementAt(0).toString() + "  " + printVal_pre.elementAt(1).toString());
    leadSpaces = ((Integer)printVal_pre.elementAt(2)).intValue();
         daysInMonth = ((Integer)printVal_pre.elementAt(3)).intValue();
         %> </B> </td>
        <td width="215"> </td>
        <td width="258" align="center"><B> <% out.println(printVal_next.elementAt(0).toString() + "  " + printVal_next.elementAt(1).toString());
        leadSpaces_next = ((Integer)printVal_next.elementAt(2)).intValue();
        daysInMonth_next = ((Integer)printVal_next.elementAt(3)).intValue();
         %> </B></td>
      </tr>
      <tr>
        <td height="151"><table width="245" border="1">
          <tr>
            <th width="35" scope="col"><div align="center">S</div></th>
            <th width="35" scope="col"><div align="center">M</div></th>
            <th width="35" scope="col"><div align="center">T</div></th>
            <th width="35" scope="col"><div align="center">W</div></th>
            <th width="35" scope="col"><div align="center">T</div></th>
            <th width="35" scope="col"><div align="center">F</div></th>
            <th width="35" scope="col"><div align="center">S</div></th>
          </tr><tr>
         <% col_Counter = 0;
              for (int i = 0; i < leadSpaces; i++) {
                   out.print("<td> </td>");
                   col_Counter++;
              for (int i = 1; i <= daysInMonth; i++) {
                   // This "if" statement is simpler than messing with NumberFormat
                   if(i < 9) {
                        out.print("<td align='center'>" + " " + i + "</td>");
                        col_Counter++;
                   } else {
                        out.print("<td align='center'>" + i + "</td>");
                        col_Counter++;
                   if ((leadSpaces + i) % 7 == 0) { // Wrap if EOL
                        out.println("</tr><tr>");
              int cnt = col_Counter;
              if(col_Counter == 28){
                   out.println("</tr>");
              }else {
                   for(int i = 0; i < (42 - col_Counter);i++){
                        out.print("<td> </td>");
                        cnt++;
                        if((cnt%7) ==0)
                             out.println("</tr><tr>");
                   out.println("</tr>");
         %>
        </table></td>
        <td> </td>
        <td><table width="245" border="1">
          <tr>
            <th width="35" scope="col"><div align="center">S</div></th>
            <th width="35" scope="col"><div align="center">M</div></th>
            <th width="35" scope="col"><div align="center">T</div></th>
            <th width="35" scope="col"><div align="center">W</div></th>
            <th width="35" scope="col"><div align="center">T</div></th>
            <th width="35" scope="col"><div align="center">F</div></th>
            <th width="35" scope="col"><div align="center">S</div></th>
          </tr>
          <tr>
           <% col_Counter = 0;
              for (int i = 0; i < leadSpaces_next; i++) {
                   out.print("<td> </td>");
                   col_Counter++;
              for (int i = 1; i <= daysInMonth_next; i++) {
                   // This "if" statement is simpler than messing with NumberFormat
                   if(i < 9) {
                        out.print("<td align='center'>" + " " + i + "</td>");
                        col_Counter++;
                   } else {
                        out.print("<td align='center'>" + i + "</td>");
                        col_Counter++;
                   if ((leadSpaces_next + i) % 7 == 0) { // Wrap if EOL
                        out.println("</tr><tr>");
              cnt = col_Counter;
              if(col_Counter == 28){
                   out.println("</tr>");
              }else {
                   for(int i = 0; i < (42 - col_Counter);i++){
                        out.print("<td> </td>");
                        cnt++;
                        if((cnt % 7 ) ==0)
                        out.println("</tr><tr>");
                   out.println("</tr>");
         %>
        </table></td>
      </tr>
      <tr>
        <td colspan="3"><table width="735" height="383" border="1">
          <tr>
          <td colspan="7" align="center"><B> <% out.println(printVal_cur.elementAt(0).toString() + "  " + printVal_cur.elementAt(1).toString());
        leadSpaces = ((Integer)printVal_cur.elementAt(2)).intValue();
        daysInMonth = ((Integer)printVal_cur.elementAt(3)).intValue();
         %> </B></td>
          </tr>
          <tr>
            <th width="105" scope="col">SUN</th>
            <th width="105" scope="col">MON</th>
            <th width="105" scope="col">TUE</th>
            <th width="105" scope="col">WED</th>
            <th width="105" scope="col">THUR</th>
            <th width="105" scope="col">FRI</th>
            <th width="105" scope="col">SAT</th>
          </tr>
          <form name="eventCal" method="post" action="Web_Cal.jsp">
          <input name="eventMonth" type="hidden" value="<%= myCal.getCur_month() + 1 %>">
           <input name="eventYear" type="hidden" value="<%=myCal.getCur_year() %>">
          <input name="action" type="hidden" value="">
          <tr>
            <% col_Counter = 0;
              for (int i = 0; i < leadSpaces; i++) {
                   out.print("<td> </td>");
                   col_Counter++;
              for (int i = 1; i <= daysInMonth; i++) {
                   // This "if" statement is simpler than messing with NumberFormat
                   if(i < 9) {
                        out.print("<td align='center'>" + " " + "<a href='javascript:openWin(document.eventCal," + i + ");'>" + i + "</a></td>");
                        col_Counter++;
                   } else {
                        out.print("<td align='center'>" + "<a href='javascript:openWin(document.eventCal," + i + ");'>" + i + "</a></td>");
                        col_Counter++;
                   if ((leadSpaces + i) % 7 == 0) { // Wrap if EOL
                        out.println("</tr><tr>");
              if(col_Counter == 28){
                   out.println("</tr>");
              }else if(col_Counter < 35){     
                   for(int i = 0; i < (35 - col_Counter);i++)
                        out.print("<td> </td>");
                   out.println("</tr>");
              }else {
                   for(int i = 0; i < (42 - col_Counter);i++)
                        out.print("<td> </td>");
                   out.println("</tr>");
         %> </form>
        </table></td>
      </tr>
    </table>
    </body>
    </html>
    </hbj:textView>
        </hbj:page>
    </hbj:content>
    Regards,
    Janvi

  • How to register jsp pages in Oracle E- business suite

    Hi Every one,
    We will see some jsp pages in Oracle Applications.
    If we create our custom jsp what procedure should we follow to register that jsp as menu function.
    Tried just like registering like OAF page buit didn't given any result.
    So if anybody are aware of this topic please guide me.
    Regards,
    Krishna

    Hi,
    Someone else provided this as a response to a previous post:
    http://download.oracle.com/docs/cd/B12428_15/migrate.904/b10425/asmwl04.htm#1009342

  • How get ServletContext from within JSP-page

    Hi! I was wondering how to get the ServletContext from within a JSP-page?
    /Ernstad

    The "application" implicit scripting variable is the same thing. e.g
    application.getAttribute(...);

  • Jsp page for mobile in drop down

    How to get the drop down list in the jsp page.for mobile applications
    and how to connect tha field in that drop down to backend
    we r using abstactpage to connect backend.

    answerd

  • Opening Excel  files from a JSP page

    Hi,
    I am not able to open up an Excel file through JSP.
    I am using following code snippet in JSP page
    response.setContentType("application/vnd.ms-excel");
    response.setHeader("Content-Disposition","inline; filename=Test.xls");Do i need to do additional settings for rendering Excel from a JSP
    Thanks in advance !!!

    Hi,
    In my application , we have Excel files on the server i.e we are not creating excel sheets.
    I just want to display these static excel files through a jsp.
    I am able to display the excel files by reading them into ByteArrayOutputStream
    <%
    response.setContentType("application/vnd.ms-excel");
    response.setHeader("Content-Disposition","attachment; filename=B.xls");
    ServletOutputStream so = response.getOutputStream();
    String filename = "D:\\Test.xls";
    String mimetype = "application/vnd.ms-excel";
    ByteArrayOutputStream output = new ByteArrayOutputStream();
    InputStream in = new BufferedInputStream(new FileInputStream(filename));
    byte bytebuff[] = new byte[500];
    for(int lengthread = 0; (lengthread = in.read(bytebuff)) != -1;){
    output.write(bytebuff, 0, lengthread);
    byte data[] = output.toByteArray();
    response.setContentType(mimetype);
    so.write(data);
    in.close();
    so.close();
    %>But my question is that , do i really need to do all this for rendering excel through a jsp.
    Can't i do it by just setting the content type ?
    Thanks

  • Changes not reflecting in JSP page

    Recently we upgraded our server from orion to oc4j.When on the client side any changes were made in the java bean
    its not reflecting immediately in the corresoponding jsp page or the application. We tried to look at all angels like class file in web-inf its changing there.The changes are taking place only after restarting the server. Pl give us valuable suugestion
    Regards
    Kumar

    It is correct that the change in the JavaBean is not taking effect until you restart the server (as far as I know anyway).
    If you are using version 9.0.4 or using a version that uses JDP 1.4.x try using the HotSwap tool which can dynamically reload classes on the fly. Excellent tool for development but not sure if it is recommended for a Production environment.
    Also, if you are using JDK 1.4.x, try using JDeveloper 10g and it's excellent debugging tools for development, it will swap your classes into the running JVM if the debugger is switched on.

Maybe you are looking for

  • USB problems on my Macbook Pro 15"

    Hello all, I just purchased a macbook pro 15" with an i5 processor (2.4 GHz, 4.0 GB RAM) a week ago and im trying to transfer my stuff from windows computer to this macbook. I have 2 usbs, one is jus a regular SONY VAIO 32 GB USB 2.0 and the other on

  • Vendor balance display (fk10n)

    hi gurus, i have a problem in transactions fk10n(vendor balance display) there are three i/p fields 1-vendor,2-company code 3-fiscal year, my task is that i have to add one more field plant code so that our display is shown according to plant code al

  • Dolby Decod

    Ok like every one else on the board i am happy that my sound no longer crackles or pops, and i have definately experienced an improvement of quality in sound, but, and this maybe a newb question and for that I'm sorry but does anyone know when the Xf

  • Screen Painter and existing forms

    Hi all, Is it possible to save one of the existing forms, for example, the item master form to an xml file that can be manipulated in the screen painter?  If it is possible, how would I do it? TIA, Steve

  • Conversion factor error in sales order - Unit of measure

    Hi All, I have uploaded a sales item in to sales order with alternate UoM. The base unit of measure for that material is TO but i have uploaded with a alternate UoM KG. After that i have created project deliveries, invoices and accounted those invoic