Error in accessing servlet from JSP

Hello everybody,
When I access a servlet from a JSP page,I am getting the following error message :
Error 404--Not Found
From RFC 2068 Hypertext Transfer Protocol -- HTTP/1.1:
10.4.5 404 Not Found
The server has not found anything matching the Request-URI. No indication is given of whether the condition is temporary or permanent.
If the server does not wish to make this information available to the client, the status code 403 (Forbidden) can be used instead. The 410 (Gone) status code SHOULD be used if the server knows, through some internally configurable mechanism, that an old resource is permanently unavailable and has no forwarding address.
I am using Weblogic 7.0 and my web.xml code is as follows:
<web-app>
<servlet>
<servlet-name>TestServlet</servlet-name>
<servlet-class>TestServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>TestServlet</servlet-name>
<url-pattern>/TestServlet</url-pattern>
</servlet-mapping>
</web-app>
I am accessing the servlet from a javascript function in my JSP page.
I am quite new to the Java technology. So any help in this regard would be highly appreciated.
Thanks in advance,

The form action event is in a javascript function. I am sorry I mentioned that I am accessing this servlet from JSP. Actually,this servlet is accessed from an HTML document.
The following is the javascript code:
<script language="javascript">
function lfnCallNext()
     alert("In the function");
     frmMain.method="POST";
     frmMain.action="/TestServlet";
     frmMain.hidChoice.value="GetList";
     frmMain.submit();
</script>
And this function is called from an hyperlink as follows:
Work with Employee Database
Thanks,

Similar Messages

  • Error when accessing Entity from JSP

    I'm trying to develop an application in Jboss AS.
    I have an Entity Class named Users and a stateful session named LoginActionBean which has the following method:
      public Users checkUser(String t1,String t2){
             Users test = (Users) em.createNamedQuery("Users.login").setParameter("userUsername",t1).setParameter("userPwd",t2).getSingleResult();
                return test;
        }In my jsp file, I try to do the following:
    Users a;
    public void jspInit() {
        try {
            InitialContext ic = new InitialContext();
            bci = (LoginActionLocal) ic.lookup("deytera_pasxa/LoginActionBean/local");
        } catch (Exception ex) {
            System.out.println("Error:"+
                    ex.getMessage());
    try {
        s2 = request.getParameter("username");
        s3 = request.getParameter("password");
        if (s2 != null && s3 != null) {
                a = bci.checkUser(s2,s3);
    .....I get no compilation error but when I try to run it I get:
    20:28:08,650 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception
    java.lang.NoSuchMethodError: ejb.LoginActionLocal.checkUser(Ljava/lang/String;Ljava/lang/String;)Lejb/Users;
            at org.apache.jsp.isLogged_jsp._jspService(isLogged_jsp.java:90)
            at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
            at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
            at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:336)
            at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
            at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
            at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
            at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
            at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
            at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
            at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
            at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
            at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
            at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
            at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
            at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
            at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
            at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
            at java.lang.Thread.run(Thread.java:595)at the moment checkUser() is called. If I change the method's return type to let's say boolean and change the code, it works perfectly fine!
    I'm stuck here for 3 hours, any help much appreciated.
    Edited by: SyMpToM on May 5, 2008 11:03 AM
    Edited by: SyMpToM on May 5, 2008 11:04 AM

    The form action event is in a javascript function. I am sorry I mentioned that I am accessing this servlet from JSP. Actually,this servlet is accessed from an HTML document.
    The following is the javascript code:
    <script language="javascript">
    function lfnCallNext()
         alert("In the function");
         frmMain.method="POST";
         frmMain.action="/TestServlet";
         frmMain.hidChoice.value="GetList";
         frmMain.submit();
    </script>
    And this function is called from an hyperlink as follows:
    Work with Employee Database
    Thanks,

  • Accessing Servlets from JSPs

    Hi!
    I'm developing a web application with JSPs and servlets using JDeveloper 3.2.
    With the integrated web-to-go web server I can either start a JSP environment or a servlet environment.
    My question: What do I have to do to start the JSP environment with access to servlets?
    I tried to start the wizard Web Object Manager, but I get the error message "Could not load servlet information from Web Server". When I try to register a Servlet in this wizard, it will hang up.
    What's wrong? Are there any other possibilities to configure the web-to-go web server, so that I can access JSPs and servlets?
    Thanks for your help!
    Brian

    Hi!
    I finally found the solution myself.
    The problem was that the entry "HTML source" under "Project Properties" was empty. I entered "servlets" and started the "Web Object Manager" without any problem. My servlet was registered and I could access it from my JSP.
    I hope that you can benifits from my experience.
    Cu
    Brian

  • Error in invoking servlet from JSP

    Hi - again!
    after being thoroughly reprimanded for posting on the wrong board, and hence seeing the error in my ways, all help greatly appreciated....
    I have read elsewhere that it is possible to call a servlet (which produces HTML) from within a JSP, thus keeping a nice clean MVC paradigm and making it easier for non-java people to design the front-end.
    I am having difficulty getting it to work and any help is much appreciated:
    My servlet (Mole):
    protected void processRequest(HttpServletRequest request, HttpServletResponse response)
        throws ServletException, IOException {
            response.setContentType("text/html;charset=UTF-8");
            PrintWriter out = response.getWriter();
            try {
                out.write("###some html stored in DB#####");
            } finally {
                out.close();
        }my JSP:
    <jsp:include page="Mole" flush="false"></jsp:include>the error I get
    Internal error flushing the buffer in release()
    StandardWrapperValve[jsp]: PWC1406: Servlet.service() for servlet jsp threw exception
    java.io.IOException: Stream closed
            at org.apache.jasper.runtime.JspWriterImpl.ensureOpen(JspWriterImpl.java:257)
            at org.apache.jasper.runtime.JspWriterImpl.clearBuffer(JspWriterImpl.java:206)
            at org.apache.jsp.CMS.services_jsp._jspService(services_jsp.java from :176)
            at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:93)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
            at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:373)
            at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:470)
            at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:364)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
            at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:317)
            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198)
            at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)
            at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230)
            at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198)
            at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:288)
            at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
            at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
            at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
            at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
            at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
            at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
            at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:272)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:341)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:263)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:214)
            at com.sun.enterprise.web.portunif.PortUnificationPipeline$PUTask.doTask(PortUnificationPipeline.java:380)
            at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
            at com.sun.enterprise.web.connector.grizzly.ssl.SSLWorkerThread.run(SSLWorkerThread.java:106)Any pointer as to what I am donig wrong?
    many thanks

    in your web.xml
    <servlet>
    <servlet-name>Mole</servlet-name>
    <servlet-class>srvlt.Mole</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>Mole</servlet-name>
    <url-pattern>/Mole</url-pattern>
    </servlet-mapping>
    package srvlt;
    // Import servlet packages
    import javax.servlet.*;
    import javax.servlet.http.*;
    // Import other Java packages
    import java.io.*;
    public class Mole extends HttpServlet {
            public void init() throws ServletException {}
            public void doGet(HttpServletRequest request, HttpServletResponse response)
                    throws ServletException, IOException {
                response.setContentType("text/html;charset=UTF-8");
                PrintWriter out = response.getWriter();
                try {
                    out.write("###some html stored in DB#####");
                } finally {
                    out.close();
    }in your jsp
    <jsp:include page="/Mole" flush="false"></jsp:include>

  • Error: cannot access directory oracle\jsp\runtime

    I got this error when try to add a existing project to JDeveloper 9.0.3.4
    Error: cannot access directory oracle\jsp\runtime; verify that directory is reachable from classpath and/or sourcepath
    can someone help me?
    thanks

    Xinwei -
    Make sure you have added the correct libraries to your project; adding JSP Runtime to your project should alleviate this error.
    Hope this helps,
    Lynn
    Java Tools Team

  • How to call Servlet from jsp page and how to run this app using tomcat..?

    Hi ,
    I wanted to call servlet from jsp action i.e. on submit button of JSP call LoginServlet.Java file.
    Please tell me how to do this into jsp page..?
    Also i wanted to execute this application using tomcat.
    Please tell me how to do this...? what setting are required for this...? what will be url ..??
    Thanks.

    well....my problem is as follows:
    whenever i type...... http://localhost:8080/appName/
    i am getting 404 error.....it is not calling to login.jsp (default jsp)
    but when i type......http://localhost:8080/appName/login.do........it executes servlet properly.
    Basically this 'login.do' is form action (form action='/login.do').....and i wanted to execute this from login jsp only.(from submit button)
    In short can anyone please tell me how to diaplay jsp page using tomcat 5.5
    plz help me.

  • How to get an ArrayList Object in servlet from JSP?

    How to get an ArrayList Object in servlet from JSP?
    hi all
    please give the solution for this without using session and application...
    In test1.jsp file
    i am setting values for my setter methods using <jsp:usebean> <jsp:setproperty> tags as shown below.
    After that i am adding the usebean object to array list, then using request.setAttribute("arraylist object")
    ---------Code----------
    <jsp:useBean id="payment" class="com.common.PaymentHandler" scope="request" />
    <jsp:setProperty name="payment" property="strCreditCardNo" param="creditCardNumber" />
    <%-- <jsp:setProperty name="payment" property="iCsc" param="securityCode" /> --%>
    <jsp:setProperty name="payment" property="strDate" param="expirationDate" />
    <jsp:setProperty name="payment" property="strCardType" param="creditCardType" />
    <%--<jsp:setProperty name="payment" property="cDeactivate" param="deactivateBox" />
    <jsp:setProperty name="payment" property="fAmount" param="depositAmt" />
    <jsp:setProperty name="payment" property="fAmount" param="totalAmtDue" /> --%>
    <jsp:useBean id="lis" class="java.util.ArrayList" scope="request">
    <%
    lis.add(payment);
    %>
    </jsp:useBean>
    <%
    request.setAttribute("lis1",lis);
    %>
    -----------Code in JSP-----------------
    In testServlet.java
    i tried to get the arraylist object in servlet using request.getAttribute
    But I unable to get that arrayObject in servlet.....
    So if any one help me out in this, it will be very helpfull to me..
    Thanks in Advance
    Edward

    Hi,
    Im also facing the similar problen
    pls anybody help..
    thax in advance....
    Litty

  • Wot all ways are there to call servlet from jsp

    hi all
    i want to know wot all methods are available
    so that i can call servlet from jsp
    the one which i know is using RequestDispatcher
    wot are others ?
    thanx

    hi all
    i want to know wot all methods are available
    so that i can call servlet from jsp
    the one which i know is using RequestDispatcher
    wot are others ?
    thanxhi here are few ways... to call servlet from jsp...
    these are just generic syntax.
    Form:     
    <form action="ServletPath">
    Link:     
    Directives & Action tags :
    <%@ page import="ServletPath" %>
         <%@ taglib uri="ServletPth" %>
         <jsp:include page="ServletPath">
         <jsp:forward page="ServletPath">
         <jsp:useBean class="ServletPath"> (Not sure about this useBean)
    hope you got your answer.
    regards,
    immu

  • Error: cannot access class oracle.jsp.runtime.HttpJsp; file oracle\jsp\runtime\HttpJs

    Hello,
    where is now oracle\jsp\runtime\HttpJsp.class located?
    thanks.
    Oleg.

    Same problem,
    Error: cannot access class oracle.jsp.runtime.HttpJsp; file oracle\jsp\runtime\HttpJsp.class not found
    Thanks
    aldo

  • SP which returns error cannot access rows from a non-nested table item.

    Dear Experts
    I have an SP which gives error " cannot access rows from a non-nested table item ". But here the strange thing is, it works fine with one query. But I write union query with another table, only then it gives error.
    CREATE OR REPLACE PROCEDURE SP_MONTHLYSALESUMMARY (
    P_TRANSACTIONMONTH VARCHAR2,
    P_LEDGERID VARCHAR2,
    O_RESULTSET OUT TYPES.CURSORTYPE)
    AS
    BEGIN
    OPEN O_RESULTSET FOR
    -- POINT OF SALE
    SELECT
    L.DESCRIPTION LEDGERNAME,
    LS.DESCRIPTION LEDGERSUBGROUPNAME,
    C.CORPORATENO
    || E.EMPLOYEENO
    || AF.AFFILIATEMEMBERNO
    || M.MEMBERNO
    AS ID,
    C.NAME || E.NAME || AF.NAME || M.NAME AS NAME,
    SUM(CASE
    WHEN PB.EMPLOYEE_ID IS NOT NULL
    AND T.ISCREDITTRANSACTIONMODE = 2
    THEN
    PB.TAXAMOUNT
    ELSE
    0
    END)
    EMPLOYEEDEBITCARDTAXAMOUNT,
    L.PRINTNO
    FROM POINTOFSALEBILL PB
    INNER JOIN POINTOFSALEBILLDETAIL PD
    ON PB.POINTOFSALEBILL_ID = PD.POINTOFSALEBILL_ID
    INNER JOIN TRANSACTIONTYPE TY
    ON TY.TRANSACTIONTYPE_ID = PB.TRANSACTIONTYPE_ID
    INNER JOIN TRANSACTIONMODE T
    ON T.TRANSACTIONMODE_ID = PB.TRANSACTIONMODE_ID
    INNER JOIN LEDGER L
    ON L.LEDGER_ID = PD.LEDGER_ID
    INNER JOIN LEDGERSUBGROUP LS
    ON LS.LEDGERSUBGROUP_ID = L.LEDGERSUBGROUP_ID
    LEFT JOIN CORPORATE C
    ON C.CORPORATE_ID = PB.CORPORATE_ID
    LEFT JOIN EMPLOYEE E
    ON E.EMPLOYEE_ID = PB.EMPLOYEE_ID
    LEFT JOIN AFFILIATEMEMBER AF
    ON AF.AFFILIATEMEMBER_ID = PB.AFFILIATEMEMBER_ID
    LEFT JOIN MEMBER M
    ON M.MEMBER_ID = PB.MEMBER_ID
    WHERE TY.ISDEBIT = 1 AND PB.FLAG = 0 AND T.ISROOMNO = 2
    AND (P_TRANSACTIONMONTH IS NULL
    OR P_TRANSACTIONMONTH =
    TO_CHAR (PB.BILLDATE, 'fmMONTH-YYYY'))
    AND (P_LEDGERID IS NULL
    OR L.LEDGER_ID IN
    ( (SELECT COLUMN_VALUE
    FROM TABLE(GET_ROWS_FROM_LIST1 (
    P_LEDGERID,
    GROUP BY L.DESCRIPTION,
    LS.DESCRIPTION,
    C.CORPORATENO
    || E.EMPLOYEENO
    || AF.AFFILIATEMEMBERNO
    || M.MEMBERNO,
    C.NAME || E.NAME || AF.NAME || M.NAME,
    L.PRINTNO;
    END SP_MONTHLYSALESUMMARY;
    GET_ROWS_FROM_LIST1 is a function, which i am using to pass " IN " to oracle. There is no problem with this, since it works fine with one query
    REATE OR REPLACE FUNCTION BCLUB1868.GET_ROWS_FROM_LIST1
    (L IN LONG DEFAULT NULL, SEP IN VARCHAR2 DEFAULT ',')
    RETURN MYVARCHARTABLE1 PIPELINED
    AS
    L_POS INT := 1;
    L_NEXT INT;
    L_PART VARCHAR(500);
    BEGIN
    SELECT INSTR( L, SEP, L_POS) INTO L_NEXT FROM DUAL;
    WHILE (L_NEXT>0)
    LOOP
    SELECT SUBSTR(L, L_POS, L_NEXT - L_POS) INTO L_PART FROM DUAL;
    PIPE ROW(L_PART);
    SELECT L_NEXT + 1, INSTR( L, SEP, L_POS)
    INTO L_POS, L_NEXT FROM DUAL;
    END LOOP;
    SELECT SUBSTR(L, L_POS) INTO L_PART FROM DUAL;
    PIPE ROW(L_PART);
    RETURN;
    END;
    Request help from you all experts in the forum

    Here it is
    CREATE OR REPLACE PROCEDURE SP_GRCS (
    P_TRANSACTIONMONTH VARCHAR2,
    P_LEDGERID VARCHAR2,
    O_RESULTSET OUT TYPES.CURSORTYPE)
    AS
    BEGIN
    OPEN O_RESULTSET FOR
    -- Point of sale
    SELECT *
    FROM ( SELECT L.DESCRIPTION LEDGERNAME,
    LS.DESCRIPTION LEDGERSUBGROUPNAME,
    C.CORPORATENO
    || E.EMPLOYEENO
    || AF.AFFILIATEMEMBERNO
    || M.MEMBERNO
    AS ID,
    C.NAME || E.NAME || AF.NAME || M.NAME AS NAME,
    SUM(CASE
    WHEN PB.EMPLOYEE_ID IS NULL
    AND T.ISCREDITTRANSACTIONMODE = 1
    THEN
    PB.BILLAMOUNT
    ELSE
    0
    END)
    MEMBERDEBITAMOUNT,
    L.PRINTNO
    FROM POINTOFSALEBILL PB
    INNER JOIN POINTOFSALEBILLDETAIL PD
    ON PB.POINTOFSALEBILL_ID = PD.POINTOFSALEBILL_ID
    INNER JOIN TRANSACTIONTYPE TY
    ON TY.TRANSACTIONTYPE_ID = PB.TRANSACTIONTYPE_ID
    INNER JOIN TRANSACTIONMODE T
    ON T.TRANSACTIONMODE_ID = PB.TRANSACTIONMODE_ID
    INNER JOIN LEDGER L
    ON L.LEDGER_ID = PD.LEDGER_ID
    INNER JOIN LEDGERSUBGROUP LS
    ON LS.LEDGERSUBGROUP_ID = L.LEDGERSUBGROUP_ID
    LEFT JOIN CORPORATE C
    ON C.CORPORATE_ID = PB.CORPORATE_ID
    LEFT JOIN EMPLOYEE E
    ON E.EMPLOYEE_ID = PB.EMPLOYEE_ID
    LEFT JOIN AFFILIATEMEMBER AF
    ON AF.AFFILIATEMEMBER_ID = PB.AFFILIATEMEMBER_ID
    LEFT JOIN MEMBER M
    ON M.MEMBER_ID = PB.MEMBER_ID
    WHERE TY.ISDEBIT = 1 AND PB.FLAG = 0 AND T.ISROOMNO = 2
    AND (P_TRANSACTIONMONTH IS NULL
    OR P_TRANSACTIONMONTH =
    TO_CHAR (PB.BILLDATE, 'fmMONTH-YYYY'))
    AND (P_LEDGERID IS NULL
    OR L.LEDGER_ID IN
    ( (SELECT COLUMN_VALUE
    FROM TABLE(GET_ROWS_FROM_LIST1 (
    P_LEDGERID,
    GROUP BY L.DESCRIPTION,
    LS.DESCRIPTION,
    C.CORPORATENO
    || E.EMPLOYEENO
    || AF.AFFILIATEMEMBERNO
    || M.MEMBERNO,
    C.NAME || E.NAME || AF.NAME || M.NAME,
    L.PRINTNO
    UNION ALL
    -- Guest Registration
    SELECT L.DESCRIPTION LEDGERNAME,
    LS.DESCRIPTION LEDGERSUBGROUPNAME,
    C.CORPORATENO
    || E.EMPLOYEENO
    || AF.AFFILIATEMEMBERNO
    || M.MEMBERNO
    AS ID,
    C.NAME || E.NAME || AF.NAME || M.NAME AS NAME,
    SUM(CASE
    WHEN PB.EMPLOYEE_ID IS NULL
    AND T.ISCREDITTRANSACTIONMODE = 1
    THEN
    PB.BILLAMOUNT
    ELSE
    0
    END)
    MEMBERDEBITAMOUNT,
    L.PRINTNO
    FROM GUESTREGISTRATION PB
    INNER JOIN GUESTREGISTRATIONDETAIL PD
    ON PB.GUESTREGISTRATION_ID = PD.GUESTREGISTRATION_ID
    INNER JOIN TRANSACTIONTYPE TY
    ON TY.TRANSACTIONTYPE_ID = PB.TRANSACTIONTYPE_ID
    INNER JOIN TRANSACTIONMODE T
    ON T.TRANSACTIONMODE_ID = PB.TRANSACTIONMODE_ID
    INNER JOIN LEDGER L
    ON L.LEDGER_ID = PD.LEDGER_ID
    INNER JOIN LEDGERSUBGROUP LS
    ON LS.LEDGERSUBGROUP_ID = L.LEDGERSUBGROUP_ID
    LEFT JOIN CORPORATE C
    ON C.CORPORATE_ID = PB.CORPORATE_ID
    LEFT JOIN EMPLOYEE E
    ON E.EMPLOYEE_ID = PB.EMPLOYEE_ID
    LEFT JOIN AFFILIATEMEMBER AF
    ON AF.AFFILIATEMEMBER_ID = PB.AFFILIATEMEMBER_ID
    LEFT JOIN MEMBER M
    ON M.MEMBER_ID = PB.MEMBER_ID
    WHERE TY.ISDEBIT = 1 AND PB.FLAG = 0 AND T.ISROOMNO = 2
    AND (P_TRANSACTIONMONTH IS NULL
    OR P_TRANSACTIONMONTH =
    TO_CHAR (PB.BILLDATE, 'fmMONTH-YYYY'))
    AND (P_LEDGERID IS NULL
    OR L.LEDGER_ID IN
    ( (SELECT COLUMN_VALUE
    FROM TABLE(GET_ROWS_FROM_LIST1 (
    P_LEDGERID,
    GROUP BY L.DESCRIPTION,
    LS.DESCRIPTION,
    C.CORPORATENO
    || E.EMPLOYEENO
    || AF.AFFILIATEMEMBERNO
    || M.MEMBERNO,
    C.NAME || E.NAME || AF.NAME || M.NAME,
    L.PRINTNO)
    ORDER BY PRINTNO;
    END SP_GRCS;
    I have even tried adding L.Ledger_ID in select statement.

  • How to call servlet from jsp

    i m trying to call it from jsp using
    <a href="../purchaseP?orderno=<%=pno%>"><%=pno%></a>
    but its giving error..
    type Status report
    message HTTP method GET is not supported by this URL
    description The specified HTTP method is not allowed for the requested resource (HTTP method GET is not supported by this URL).

    i m trying to call it from jsp using
    <a href="../purchaseP?orderno=<%=pno%>"><%=pno%></a>
    but its giving error..
    type Status report
    message HTTP method GET is not supported by this URL
    description The specified HTTP method is not allowed
    for the requested resource (HTTP method GET is not
    supported by this URL).Are you implementing the doGet or doPost method in your servlet? If you are calling from a hyperlink then it needs to be implementing the GET method. To access the POST method use a html form.

  • Very urgent: call servlet from JSP

    Hello,
    I'm facing a problem in invoking a servlet from a JSP having the JSF components.
    The application has a text field to implement ajax for search functionality in the database .I have written a servlet to make the database connection and fire the querry.
    Ajax implementation in a js file is called on every keyup event in the jsp file,and
    a call is given to the servlet from the ajax methode.
    The function in the js file is as follows:-
    function getPersonByFirstNameXML( firstName ) {
        if (!firstName) {
            clearPersonByFirstNameXML();
        } else {   
            var url = BASE_URL + "/servlet/get_PersonsXML";
            alert(url);
            return new AJAXRequest("post", url, "firstName=" + encode(firstName), processGetPersonByFirstNameXML);
    }Im getting the myAJAX.status value as 500.
    I think I'm not able to access the servlet properly.
    what changes do i need to make in the we.xml file ?
    and what should be the url to be passed.
    Please provide me a sloution to the above problem as it is very urgent else if anybody is aware of a readymade JSF componet with search functionality freely available please let me know.
    PS:
    The sample application named RedirectionExample which makes use of a servlet and would be of help to you. You can find the tutorial on the following page:
    http://developers.sun.com/prodtech/javatools/jscreator/reference/codesamples/sampleapps.html
    is not available as stated in some of the suggestions by Author: mayagiri
    Thanks for any help.
    Abhi

    the status 500 generally means either HTTP server internal error or that execution of CGI script or servlet aborted with error.
    It can be reasonably supposed that the request reaches the servlet, ie. that "url" value points to some existing servlet, otherwise most probably the status value would be 404.
    To test that the servlet is working i'd try to access it using some simple html page with form like this (with {BASE_URL} replaced by real value):
    <form method=post action={BASE_URL}/servlet/get_PersonsXML>
    <input type=text name=firstName>
    <input type=Submit>
    </form>

  • Cannot invoke servlet from JSP

    I am trying to invoke a servlet from my JSP file. At present I am getting the error:
    500 Internal Server Error
    java.lang.IllegalArgumentException: Resource /servlet/CreateSPSS not found
         at com.evermind[Oracle Application Server Containers for J2EE 10g (10.1.2.0.2)].server.http.EvermindPageContext.forward
    I understand that my JSP cannot find my servlet but I cannot identify what the correct path or amendment is.
    My JSP file is located in:
    default-web-app/examples/jsp/com.xml2spss.jsp
    In the JSP my forward parameter is :
    <jsp:forward page="/servlet/CreateSPSS" />
    and my servlet (.java & .class) is located in
    default-web-app/WEB-INF/classes/com/pmstation/spss/site/servlet.CreateSPSS.java
    I have added the following line to Web.XML:
    <servlet-mapping>
    <servlet-name>CreateSPSS</servlet-name>
    <url-pattern>/servlet/CreateSPSS</url-pattern>
    </servlet-mapping>
    Where am I going wrong??
    Thankyou for any help at all on this one.

    Shaun,
    Nice to know that you find a way that works. However, what Zsolt suggests should work; otherwise, it is a bug. That is, put the servlet definition and servlet mapping in your web.xml and then you should be able to access http://host:port/myWebContext/servlet/CreateSPSS?myParmName=myParm without seeing a response like "No resource found". Please make sure that your servlet definition come before the corresponding servlet mapping.

  • Accessing Servlet by jsp: forward

    I want to access Servelt by hyperlink in a jsp web site
    connection.jsp
    <%@ page contentType="text/html;charset=GB2312" %>
    <HTML>
    <BODY bgcolor=cyan><Font size=1>
    <A Href="/myjsp/Hello" >Accessing servlet<A>
    </BODY>
    </HTMLi put the bean in the dir(/myjsp/WEB-INF/classes/hello(package)/Hello)
    and modify the file web.xml like this:
    <servlet>
            <servlet-name>Hello</servlet-name>
            <servlet-class>hello.Hello</servlet-class>
        </servlet>
        <servlet-mapping>
           <servlet-name>Hello</servlet-name>
           <url-pattern>/Hello</url-pattern>
        </servlet-mapping>it works!
    but if i use <jsp:forward>
    <html>
         <body bgcolor="green">
         <jsp:forward page="/myjsp/Hello" />
         <body>
    </html>it causes an Exception The requested resource (/myjsp/myjsp/SimpleServlet) is not available.
    why? why the path have /myjsp/myjsp....?
    Thanks

    only one wrong u have done that is
    U have to give :
    <jsp:forward page="/Hello"></jsp:forward>
    but not
    <jsp:forward page="/myjsp/Hello"></jsp:forward>
    the reason is that when u run a jsp file , a servlet is generated for that
    jsp file. so calling a another servlet from that servlet(servlet of connection.jsp) can be done by just giving url -pattern. No need to give
    /myjsp/Hello .
    regards,
    reply after u get

  • Error while accessing table from procedure but no error from anonymous plsq

    Hi All,
    I am getting a strange error while accessing a table from a different schema.
    In that concerned schema OWBSYS, i executed the following:
    grant Select on wb_rt_audit to ods;In Ods schema i executed:
    CREATE OR REPLACE SYNONYM wb_rt_audit FOR OWBSYS.wb_rt_audit;In ODS schema, when i execute:
    create or replace
    procedure pp_test as
    lv_owb_reject number := 0;
    lv_filename_1 varchar2(200):= 'asda';
    begin
        SELECT MAX(aud.rta_iid) into lv_owb_reject
                              FROM   wb_rt_audit aud
                              WHERE  aud.rta_lob_name LIKE Upper(lv_filename_1)
    end;
    /I get the error:
    Warning: execution completed with warning
    procedure Compiled.
    ORA-00942 - TABLE OR VIEW DOES NOT EXISTHowever, when i execute as an anonymous plsql the same code:
    declare
    lv_owb_reject number := 0;
    lv_filename_1 varchar2(200):= 'asda';
    begin
        SELECT MAX(aud.rta_iid) lv_owb_reject
                              FROM   wb_rt_audit aud
                              WHERE  aud.rta_lob_name LIKE Upper(lv_filename_1)
    end;
    anonymous block completedthere is no issue.
    Can someone help me understand what I might be missing:
    Edited by: Chaitanya on Feb 28, 2012 12:31 AM

    Check if have some other steps.
    SQL>conn scott1/tiger
    Connected.
    SQL>create table wb_rt_audit (rta_iid number);
    Table created.
    SQL>insert into wb_rt_audit values (100);
    1 row created.
    SQL>insert into wb_rt_audit values (200);
    1 row created.
    SQL>commit;
    Commit complete.
    SQL>grant select  on wb_rt_audit to scott2;
    Grant succeeded.
    SQL>conn scott2/tiger
    Connected.
    SQL>create synonym wb_rt_audit for scott1.wb_rt_audit;
    Synonym created.
    SQL>create or replace procedure pp_test as
        l_number number(10);
        begin
            SELECT MAX(rta_iid) into l_number
                                  FROM   wb_rt_audit;
      end pp_test;
    Procedure created.

Maybe you are looking for

  • Can you see game center games?

    Good afternoon all!!! This is simply a place to input our experience with Game Center... My experience is that I was successful at starting the account with my current apple id, but I am not seeing any games in the "Games" section. When I touch the "

  • Error while installing printer software for HP Photosmart Plus 209a-m on Windows 8.1 64 bit OS

    I am getting below error while installing printer software of HP Photosmart Plus 209a-m on Windows 8.1 64 bit OS. Can you please help me resolve this error? Thanks in advance.

  • My downloads are not appearing in the download folder

    (using mac) My download window--I can click on items that are there and "show in finder" and then they appear in the finder...but otherwise, my downloads folder has no new items in it and even if I search with the right file name, it will not appear.

  • Space allocation on 11g R2 on multiple data files in one tablespace

    hello if the following is explained in Oracle 11g R2 documentation please send a pointer. I cant find it myself right now. my question is about space allocation (during inserts and during table data load) in one table space containing multiple data f

  • OBIEE 11g - zeros and nulls and rows, oh my!

    Hi, dumb question here, but I need some help with handling zeros and nulls with OBIEE. First off, I have a fact table that contains five "metrics" - A, B, C, D, and E. Often (but not always), only 1 of the 5 columns is populated, the others are NULL.