Working of vo.executeQuery()

Can someone clarify on the following:
1.Does vo.executeQuery() always get data from database or it first searches the view cache in turn entity cahe and then the database?
2.What happens if we add a dynamic where clause and execute query, will the proces be different if we run query by example?
Thanks

I have made a simple testing scenario using Jdeveloper 11g and JSF page
I added a button the programmatically traverses an Entity based ViewObject on which the JSF page is built
I concluded the following
1)The executeQuery visited the database every time it is executed even if the user made no changes on the JSF, i verified that using the EXECUTIONS and ROWS_PROCESSSED fields of the V$SQLAREA view.
2)The user Added a Row through the JSF page (CreateInsert) without committing the data, the ExecuteQuery showed this row and obviously retrieved it from its Cache.
3)The user modified an existing Row through the JSF page without committing and the ExecuteQuery showed the modified row. Clearly the framework fetch the dirty row from its cache.
4)I created a row directly through SQL*Plus and committed the row , and upon using the JSF ExcuteQuery , the new row appeared among the other results described above.
5)I tried to modify the row that is updated in step (3) using SQL*Plus , the row was locked by the framework (due to default lock mode)
==> Simply stated, over the span of one transaction, Execute Query fetches dirty data from the Entity Cache, while at the same time, fetches non-dirty including committed data from the database
Oracle forms developer will face some issues since the behaviour is a bit different. In oracle forms, whenever the user modified a row on the UI page and follows it by Execute_Query command, a Message asking the user if he/she wants to commit the changes first. The result of the query is then depended on the answer. If No, changes are ignored and the page is refreshed from the database.
I am still having a little bit of confusion with Refresh() functionality. Refresh as i read has to do with associating an AM in the pool back with its binding iterator! There are method like refresh(ROW.undo-changes .... ) which indicate a database visit sometimes
Ammar Sajdi
Ammar

Similar Messages

  • Reading multiple result sets using executeQuery

    Hi - We have a database Proc that returns multiple result sets as the out params.
    Following is the line that does the DB call.
    rows = DynamicSQL.executeQuery(sentence : query, implname : "Sql Server");
    The 'rows' param above is able to get only the first result set after. It ignores the rest of the Out params.
    Do we have any way other than changing the proc to send one out param to handle this?
    Thanks!
    VVP

    This worked:
    rows = myDynamic.executeQuery(sentence : SaveQueryForMAPS, implname : "MAPS");
    foreach (row in rows) {
    //status = 0;
    status = row[1];
    display("status" +status);
    Thank you so much for your idea Andrea!

  • Get Rows based on  value of a certain Attribute

    Hi guys,
    i was trying to get all the rows from the cache as well as the Database for my VO
    For that i used getFilteredRows() as well as findByKey() method.
    But i could not get any rows.
    Also i had a doubt for the findByKey() method. Do we need to use Primary key as Key or do can we use any attribute as the Key?

    Hi Pradeep,
    I think getFilteredRows() works only after executeQuery() has brought the rows to cache. I do not know if getFilteredRows() runs executeQuery() implicitly. Maybe you can use a ViewCriteria object in order to create a criteria based on the attribute, and then find it by this criteria.
    As for your other question, findByKey acts upon all attributes of the view object that are marked as Key attribute. You can mark any attribute as key, whether or not it is a primary key constituent, by setting the Key Attribute Checkbox on the Attribute Definition, inside the View Object Wizard.
    Hope it helps,
    Thiago

  • SQL STATEMENT JDBC

    I am trying to modify column size to Access. If str has 23 char and md(from Access with JDBC) has 20 char, then it must change 20 char to 23 char because I want to expand more chars.
    if(md.getColumnDisplaySize(j) < Integer.parseInt(str))
    st.executeUpdate("alter table IKB modify ( Firstname char (" + str[i] +"))");
    I got this:java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Syntax error in ALTER TABLE statement. I mean I checked sql sites to make sure that I am not doing with wrong sql statement. Please Tell me what I did wrong.
    Thank you

    Hi,
    sorry to bother you with a question but you're obviously more advanced than I am with Java.
    I'm trying to do a simple insert statement in Java but it doesn't work:
    rec2 = st2.executeQuery("INSERT INTO chequetable VALUES ('1', '2', '3', '4', '5', 94, '6', '7', '8', '9');");
    my record has 10 fields all being a string except for field 6.
    When I run this I get a SQL Error 0 S1000
    Have you got an example of a simple SQL insert statement through Java.
    Incidentally, I've been playing with Swing quite extensively so if you have any questions on that subject I'd be happy to help.
    M.A.D

  • Strange Binding Behaviour in taskflow..

    Dear All,
    I have 2 pages in a taskflow.
    1. shows a table.
    2. shows details when the user clicks the row in the page 1(its a separate page).
    every thing is working fine except the following problem.
    Suppose i selected the row in first page which opened the second page(detail). When the page was opened i manually edited the record in database and then refreshed the page(F5)... The result was the change was not reflected.
    I went back to page1 and selected the same row which opened the same detail page but still the change was not reflected...?
    I opened the page in other browser which showed me the change done in database table...??
    Is'nt it strange...? i think it is doing some type of caching or something..
    Can anyone provide me pointers for this problem..
    Regards,
    Santosh.
    jdeveloper 11.1.1.4.0

    you need to re-execute your query to see the changes in database:
    check this useful notes:
    Re: working of vo.executeQuery()

  • Sort LOV view with transient attribute

    Hello,
    I am using JDeveloper 12c.
    I have a view object with a list of value. Let's say EmployeeView and EmployeeStatusLovView.
    I have a transient attribute on my list of values. Let's say statusDescription.
    I want to sort my list of value with the transient attribute. How can I do that ?
    I saw that I can easy sort with non transient attribute.
    If it wasn't a LOV, I could override the executeQuery and call setSortBy(), but with a LOV it doesn't work as the executeQuery isn't called.
    Any ideas?
    Thanks,
    Cindy

    Ok I get it. The problem was that I tried to override the executeQuery() instead of executeQueryForCollection(). With LOV the first one is not used. Calling setSortBy("myTransientAttribute") in executeQueryForCollection() works just fine!

  • ExecuteQuery() fails with -2146232000 on Windows 8.1 (works great on Server 2013)

    When executing a small console app on my Windows 8.1, I get an error:
    {"Name cannot begin with the ' ' character, hexadecimal value 0x20. Line 95, position 36."}
    The code:
    ClientContext ctx = Create();
    Web web = ctx.Web;
    List instNoteList = ctx.Web.Lists.GetByTitle(InstNoteListTitle);
    List instDokList = ctx.Web.Lists.GetByTitle(InstDokListTitle);
    ctx.Load(ctx.Web);
    ctx.Load(instNoteList);
    ctx.Load(instDokList);
    ctx.ExecuteQuery();
    This code works on a Server 2012 Image running HyperV: I can create lists, insert items, upload documents etc.
    But on my host OS, this code fails.
    Jorgen

    I had the exact same issue and the exception was thrown at Line 95, position 36 when trying to access
    our Sharepoint Online site. Is this related to authentication? I tried with multiple valid accounts and none of them worked so the chances of incorrect credentials should be low.
    Here is the stacktrace
       at System.Xml.XmlTextReaderImpl.Throw(Exception e)
       at System.Xml.XmlTextReaderImpl.Throw(String res, String[] args)
       at System.Xml.XmlTextReaderImpl.ParseQName(Boolean isQName, Int32 startOffset, Int32& colonPos)
       at System.Xml.XmlTextReaderImpl.ParseElement()
       at System.Xml.XmlTextReaderImpl.ParseElementContent()
       at System.Xml.XmlTextReaderImpl.Read()
       at System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r)
       at System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r, LoadOptions o)
       at System.Xml.Linq.XDocument.Load(XmlReader reader, LoadOptions options)
       at System.Xml.Linq.XDocument.Load(XmlReader reader)
       at Microsoft.SharePoint.Client.Idcrl.IdcrlAuth.DoGet(String url)
       at Microsoft.SharePoint.Client.Idcrl.IdcrlAuth.RequestFederationProviderInfo(String domainname)
       at Microsoft.SharePoint.Client.Idcrl.IdcrlAuth.GetFederationProviderInfo(String domainname)
       at Microsoft.SharePoint.Client.Idcrl.IdcrlAuth.InitFederationProviderInfoForUser(String username)
       at Microsoft.SharePoint.Client.Idcrl.IdcrlAuth.GetServiceToken(String username, String password, String serviceTarget, String servicePolicy)
       at Microsoft.SharePoint.Client.Idcrl.SharePointOnlineAuthenticationProvider.GetAuthenticationCookie(Uri url, String username, SecureString password)
       at Microsoft.SharePoint.Client.SharePointOnlineCredentials.GetAuthenticationCookie(Uri url, Boolean refresh)
       at Microsoft.SharePoint.Client.ClientRuntimeContext.SetupRequestCredential(ClientRuntimeContext context, HttpWebRequest request)
       at Microsoft.SharePoint.Client.SPWebRequestExecutor.GetRequestStream()
       at Microsoft.SharePoint.Client.ClientContext.GetFormDigestInfoPrivate()
       at Microsoft.SharePoint.Client.ClientContext.EnsureFormDigest()
       at Microsoft.SharePoint.Client.ClientContext.ExecuteQuery()
    Any suggestions?

  • ExecuteQuery button doesn't work on FORM6

    I created a form for customer personal data update. One of my buttons on the form, "AddCompanyId", brings up a pop-up window (as a new canvas) which is basically a tabular form containing "CompanyID, CompanyName, etc.". I filled the table's CompanyName with a pattern, such as "Orac%", in the first row (I'm trying to retrieve all companies matching the pattern).
    I then use a "ExecuteQuery" button on this pop-up window. I set the button belong to the root canvas and in the button's trigger code, I used
    "go_block('block_of_the_new_canvas'); execute_query;".
    When I pushed the "ExecuteQuery" button, it did not give me a list of companies I was expecting. The message on the status bar says "Enter a query. Press F8 to execute". Pressing F8 key does give me the results, but I want the results by using my "ExecuteQuery" button. What did I do wrong? Your help is greately appreciated.
    Wendy

    Dear Wendy
    there are two option one that seems is, you are in the enter query mode that is why the message.
    you can get the result in two ways. one by using enter query and then enter the value in the filed and execute it. make sure that at the time of enter-query the focus is on the block on which you want to run the query.
    other is try following and check
    Since you have a new block on a new canvas and you want to perform execute Query funtion on it.
    make sure that the block is a base table block.
    make sure that the fileds in the block are equall are less than the no of fileds in the base table which have basetable item property set to yes.
    and while excuting the query make sure to send the focus to Query block, which you are doing by calling go_block funtion.
    and since you want the specified values to be fetched only. Do write the pre-query trigger and set the default where condition in it.
    set_block_property('block_name',default_where,'where condition');
    in your case stored the entered value in a variable Local(in pre-query trigger) or Global variable.
    and pass that variable as the condition.
    set_block_property('block_name',default_where,'database_fieldname like variable_name ');
    Try This
    Pre-Query trigger
    Declare
    variable_name varchar2;
    Begin
    variable_nam := ('%'&#0124; &#0124;:block.item_name&#0124; &#0124;'%');
    set_block_property('blockname',default_where,'basetable_fieldname like :variable_name');
    end;
    Also Check if you had wriiten enter_query any where remove it is not not needed in this case.
    Hopes it will work for you.
    ZAM
    null

  • Vo.executeQuery() not working

    Hi All,
    I am new to the world of OAF.I need to customize an OAF page(11i). I am trying to populate data from FND table using VO.
    My VO query:
    <SQLQuery><![CDATA[
    select lookup_code as  skuid1,meaning as descr, null as count_1,null as serialno , tag as tag from apps.fnd_lookup_values flv
           where     lookup_type like('WWPO_FEILD_PHY_SKU_MAINTANANCE')
          AND    enabled_flag = 'Y'
          AND    NVL ( start_date_active, TO_CHAR ( SYSDATE, 'DD-MON-RRRR' ) ) <=
                                                                      TO_CHAR ( SYSDATE, 'DD-MON-RRRR' )
          AND    NVL ( end_date_active, TO_CHAR ( SYSDATE, 'DD-MON-RRRR' ) ) >=
                                                                      TO_CHAR ( SYSDATE, 'DD-MON-RRRR' )
          AND    LANGUAGE = 'US'
       ]]></SQLQuery>
    I am using a region(Table) with a submitbutton:
    My CO code:
      if (pageContext.getParameter("PopDetBtn") != null)
           am.invokeMethod("PopDet");
    My AM code :
    public void PopDet()
    XXWWPopDetVOImpl popVO = getXXWWPopDetVO1();
    popVO.setRangeSize(1);
    popVO.setWhereClause(null);
    popVO.setRangeSize(1);
    popVO.executeQuery();
    executeQuery() is not working.Data is not getting fetched. Please let me know where I am wrong.
    This is my first object in OAF.
    Regrads,
    Debanjan

    Hi Debanjan,
    Your CO Code is like this ---
        OAApplicationModule am = pageContext.getApplicationModule(webBean);
          if (pageContext.getParameter("PopDetBtn") != null) {
            am.invokeMethod("PopDet");
    And I have kept the AM Code also same.
    It is working for me. Please check your VO Query and try to run that query in database and check whether the query is returning data or not.
    I have used the simple query ---  " select * from emp "
    If you have resolved the issue, Please let me know what changes you have made.
    If you are facing any other issue, you can feel free to ask.
    Regards,
    Pawan Sarswat

  • My ViewObject.executeQuery() does'nt work

    Hi
    I have a screen with employee information.
    For which i have a rowsetinfo1 to hold employee information.
    I have a viewobject vo with a whereclause of 10
    I have executed vo.executequery() but it doesnt filter that data.
    Is there any link through which i need to link viewobject with rosetinfo1

    I checked the code, we do not have any other manipulation on the view object, the only thing different in our case that I can think of is that this code is being called the 1st time from one page in the afterPhase method of a class that implements PagePhaseListener (on page load). I'm passing the page name to the View Object, and this invokation executes okay an returns the matching one record.
    Then I navigate to another page (again in its page definition, its controller is using the same pagePhaseListener class), so when the code is executed the next time, I'm passing the new page name, but this invokation does not return any data, even though I'm sure the SQL and the page name parameter does return 1 row in SQLPlus.
    Any thing special with executing the view object parameter binding when I navigate out and back to the page?
    Appreciate the help
    Mohamed

  • IMAGEIO IS WORKING BUT BYTEARRAY IS NOT WORKING:

    Hi all
    I am getting images from gmail contacts and trying to store it in DB
    using my http code:InputStream is=urlconnection.getInputStream();
    i could able to store the inputstream in file using:
    BufferedImage filebuffer=ImageIO.read(is);
    FileOutputStream fos=new FileOutputStream("picturerecent.jpg");
    ImageIO.write(filebuffer, "jpg", fos);
    but i was trying to store it in DB using the following code but it is not working.i am having a question that
    how it writing to a file without any problem.why not to database:
    try {
           String url = "jdbc:mysql://localhost:3306/";
             String db = "test";
             String driver = "com.mysql.jdbc.Driver";
                    Class.forName(driver);
                    con = DriverManager.getConnection(url+db,"root","");
                    try{
    PreparedStatement psmnt;
         psmnt = con.prepareStatement("insert into gmailphoto(id,Photo) "+ "values(?,?)");
         psmnt.setInt(1, 9);
         psmnt.setObject(2, is, java.sql.Types.BLOB);
         int s = psmnt.executeUpdate();
           Statement st = con.createStatement();
        try{
            ResultSet rs=st.executeQuery("select photo from gmailphoto where id=9");
            if(rs.next())
              {     //byte[] bytearray = new byte[4096];
                  int size=0;
                File sImage;
    //FIRST TRY
                FileWriter wr=new FileWriter(new File("c:\\imageOutput.jpg"));
                IOUtils.copy(rs.getBlob("photo").getBinaryStream(),wr);
                //SECOND TRY
                BufferedImage bf=ImageIO.read(new ByteArrayInputStream(rs.getBytes("photo")));
                FileOutputStream fout=new FileOutputStream(new File("C:\\imageOut"));
                if(bf!=null)ImageIO.write(bf, "jpg", fout);
                if(wr!=null)
                wr.flush();
                wr.close();
              rs.close();
           }}catch(SQLException e){
                System.out.println(e);
           }Thanks a lot for help

    but i was trying to store it in DB using the following codeThere is no code here that writes to a database. There are two lots of code that write to a file.

  • Why doesn't my custom tag work?

    First, my backend database is MS Access. Nothing I can do about that, unfortunately.
    I have defined three custom tags (no body, no attributes) to display report information from my project tracking/metrics Access database:
    <prefix:showProjectInfo />
    <prefix:showProjectTeam />
    <prefix:showProjectHistory />
    In my JSP, the first tag I use, <prefix:showProjectInfo />, works perfectly. However, <prefix:showProjectTeam /> gives no output.
    First, here is the tld file that defines the tags (report.tld):
    <?xml version="1.0" encoding="UTF-8" ?>
    <!DOCTYPE taglib
            PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"
            "http://java.sun.com/dtd/web-jsptaglibrary_1_2.dtd">
    <taglib>
        <tlib-version>1.0</tlib-version>
        <jsp-version>1.2</jsp-version>
        <short-name>report</short-name>
        <uri>/report</uri>   
        <!-- Forte4J_TLDX:  This comment contains code generation information. Do not delete.
        <tldx>
            <tagHandlerGenerationRoot>classes</tagHandlerGenerationRoot>
        </tldx>
        -->
        <!-- A validator verifies that the tags are used correctly at JSP
             translation time. Validator entries look like this:
          <validator>
              <validator-class>com.mycompany.TagLibValidator</validator-class>
              <init-param>
                 <param-name>parameter</param-name>
                 <param-value>value</param-value>
           </init-param>
          </validator>
       -->
       <!-- A tag library can register Servlet Context event listeners in
            case it needs to react to such events. Listener entries look
            like this:
         <listener>
             <listener-class>com.mycompany.TagLibListener</listener-class>
         </listener>
       -->
       <tag>
            <name>showProjectInfo</name>
            <tag-class>mil.usaf.rad.metrics.report.showProjectInfoTag</tag-class>
            <body-content>empty</body-content>
            <description>Shows the basic project information</description>       
       </tag>
       <tag>
            <name>showProjectTeam</name>
            <tag-class>mil.usaf.rad.metrics.report.showProjectTeamTag</tag-class>
            <body-content>empty</body-content>
       </tag>
       <tag>
            <name>showProjectHistory</name>
            <tag-class>mil.usaf.rad.metrics.report.showProjectHistoryTag</tag-class>
            <body-content>empty</body-content>
       </tag>
    </taglib>Next, here is the relevant section of web.xml that defines this taglib:
      <taglib>
            <taglib-uri>/WEB-INF/report.tld</taglib-uri>
            <taglib-location>/WEB-INF/report.tld</taglib-location>
      </taglib>Next, the code for showProjectTeamTag.java:
    * showProjectTeam.java
    * Created on March 9, 2005, 10:46 AM
    package mil.usaf.rad.metrics.report;
    import java.io.*;
    import java.sql.*;
    import java.lang.Integer;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import javax.servlet.jsp.*;
    import javax.servlet.jsp.tagext.*;
    * @author  jason.ferguson
    public class showProjectTeamTag extends TagSupport
        public showProjectTeamTag()
            super();
        public int doAfterBody() throws JspException
            HttpServletRequest req = (HttpServletRequest) pageContext.getRequest();
            int pr_id = Integer.parseInt(req.getParameter("pr_id"));
            JspWriter out = pageContext.getOut();
            Connection conn = null;
            Statement stmt = null;
            ResultSet rs = null;
            try
               out.print("test");
               Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
               conn = DriverManager.getConnection("jdbc:odbc:Metrics");
            catch (Exception e)
                throw new JspException(e.getMessage());
            String queryGetTeam = "SELECT Projects.pr_id, Accounts.name AS Name, Sum(Schedule.hours) AS SumOfhours FROM tblTAAccounts AS Accounts INNER JOIN ((tblTAScheduleEntries AS Schedule INNER JOIN tblProjectRelease AS ProjectRelease ON Schedule.projectID = ProjectRelease.tblFKTimeAccntProject) INNER JOIN tblPMProjects AS Projects ON ProjectRelease.Release_ID = Projects.pr_id) ON Accounts.accountID = Schedule.accountID WHERE Projects.pr_id=" + pr_id + " GROUP BY Projects.pr_id, Accounts.name, ProjectRelease.Release_number, Projects.Project_name";
            try
                out.print(queryGetTeam);
                stmt = conn.createStatement();
                rs = stmt.executeQuery(queryGetTeam);
                if (rs == null)
                    out.print("No Results!");
                out.print("<table>\n");
                out.print("<tr>\n");
                out.print("<th>Name</th>\n");
                out.print("<th>Total Hours</th>\n");
                out.print("</tr>\n");
                while(rs.next())
                    out.print("<tr>\n");
                    out.print("<td>" + rs.getString("Name") + "</td>\n");
                    out.print("<td>" + rs.getInt("SumOfhours") + "</td>\n");
                    out.print("</tr>\n");
                out.print("</table>\n");
                rs.close();
                stmt.close();
                conn.close();
            catch (Exception e)
                throw new JspException(e.getMessage());
            return SKIP_BODY;
    }Finally, projectdetail.jsp, where the tag is called:
    <%@page contentType="text/html"%>
    <%@page pageEncoding="UTF-8"%>
    <%@page import="java.sql.*" %>
    <%@page import="java.lang.Integer" %>
    <%@taglib uri="/WEB-INF/report.tld" prefix="report" %>
    <html>
    <head><title>Project Detail</title></head>
    <body>
    <h1 align="center">Project Status</h1>
    <h3>Project Description</h3>
    <report:showProjectInfo />
    <h3>Team Members</h3>
    <report:showProjectTeam />
    </body>
    </html>The first tag, <report:showProjectInfo />, works fine. However, I get no output whatsoever when the system encounters <report:showProjectTeam />. I am a relative newbie at this, so any help is appreciated.
    Jason

    It doesnt seem to matter if the code is in doStartTag(), doEndTag(), orr any of the other functions.
    I also put, as the first item in the function:
    System.out.println("TEST");Nothing.
    Just as an aside, here is the code for the <prefix:showProjectInfo />. Maybe I made a mistake in it? I closed the resultset and connection...
    import java.io.*;
    import java.sql.*;
    import java.lang.Integer;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import javax.servlet.jsp.*;
    import javax.servlet.jsp.tagext.*;
    * @author  jason.ferguson
    public class showProjectInfoTag extends BodyTagSupport
        public int doEndTag() throws JspException
            HttpServletRequest req = (HttpServletRequest) pageContext.getRequest();
            int pr_id = Integer.parseInt(req.getParameter("pr_id"));
            JspWriter out = pageContext.getOut();
            Connection conn = null;
            Statement stmt = null;
            ResultSet rs = null;
            try
               Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                conn = DriverManager.getConnection("jdbc:odbc:Metrics");
            catch (Exception e)
                throw new JspException(e.getMessage());
            String queryProjectInfo = "SELECT * FROM tblPMProjects WHERE pr_id=" + pr_id;
            try
                stmt = conn.createStatement();
                rs = stmt.executeQuery(queryProjectInfo);
                while (rs.next())
                    out.print("<table border=\"1\" style=\"border-collapse:collapse\">\n");
                    out.print("<tr>\n");
                    out.print("<td><b>Project Name:</b>" + rs.getString("Project_name") + "</td>\n");
                    out.print("<td align=\"right\"><b>RAD Number:</b>" + rs.getString("tblProjectNumber") + "</td>\n");
                    out.print("</tr>\n");
                    out.print("<tr>\n");
                    out.print("<td>Project description: " + rs.getString("Project_description") + "</td>\n");
                    out.print("</tr>\n");
                    out.print("<tr>\n");
                    out.print("<td>Customer: " + rs.getString("Customer_POC") + "</td>");
                    out.print("<tr>\n");
                    out.print("<tr>\n");
                    out.print("<td>Customer Unit: " + rs.getString("Customer_OFC") + "</td>\n");
                    out.print("</tr>\n");
                    out.print("<tr>\n");
                    out.print("<td>Customer Phone: " + rs.getString("Customer_phone") + "</td>\n");
                    out.print("</tr>\n");
                    out.print("</table>\n");
                    rs.close();
                    stmt.close();
                    conn.close();
            catch (Exception e)
                throw new JspException(e.getMessage());
            finally
                //conn.close();
            return SKIP_BODY;

  • EP5.0 Custom .par File Does Not Work in EP6.0 SP2

    I have a .par file called CustomerSearch.par that is used in EP5.0, and I am now trying to get this .par file to work in EP6.0 SP2.  I noticed the directory structure changes, so my .par structure is this:
    CustomerSearch.par
    -->  portal-inf
    portalapp.xml
    lib
    CustomerSearch.jar
    TableViewExample.class
    pagelet
    TableView.jsp
    I am getting the following error in the portal console logs when I try to access the component after I have uploaded the CustomerSearch.par file.  Does anyone have any suggestions?
    Error Message
    Jan 26, 2005 4:23:50 PM # Client_Thread_34 Fatal Exception ID:04:23_26/01/05_0019
    com.sapportals.portal.prt.component.PortalComponentException: Error in service call of Resource
    Component : CustomerSearch.TableViewExample
    Component class : TableViewExample
    User : testUser
    at com.sapportals.portal.prt.core.PortalRequestManager.handlePortalComponentException(PortalRequestManager.java:858)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:389)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:462)
    at com.sapportals.portal.prt.component.AbstractComponentResponse.include(AbstractComponentResponse.java:88)
    at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:226)
    at com.sapportals.portal.htmlb.page.JSPDynPage.doOutput(JSPDynPage.java:76)
    at com.sapportals.htmlb.page.PageProcessor.handleRequest(PageProcessor.java:109)
    at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.java:135)
    at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)
    at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)
    at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:300)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:190)
    at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:209)
    at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:576)
    at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:300)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:190)
    at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:669)
    at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:208)
    at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:532)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:415)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.inqmy.services.servlets_jsp.server.InvokerServlet.service(InvokerServlet.java:126)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.inqmy.services.servlets_jsp.server.RunServlet.runSerlvet(RunServlet.java:149)
    at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl.java:833)
    at com.inqmy.services.httpserver.server.RequestAnalizer.checkFilename(RequestAnalizer.java:665)
    at com.inqmy.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:312)
    at com.inqmy.services.httpserver.server.Response.handle(Response.java:173)
    at com.inqmy.services.httpserver.server.HttpServerFrame.request(HttpServerFrame.java:1229)
    at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:36)
    at com.inqmy.core.cluster.impl5.ParserRunner.run(ParserRunner.java:55)
    at com.inqmy.core.thread.impl0.ActionObject.run(ActionObject.java:46)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.inqmy.core.thread.impl0.SingleThread.run(SingleThread.java:148)
    Caused by: com.sapportals.portal.prt.component.PortalComponentException: PortalComponentException
    at com.sapportals.portal.prt.servlets_jsp.server.jsp.JSPCompiler.run(JSPCompiler.java:123)
    at com.sapportals.portal.prt.core.broker.JSPComponentItem.compileJSP(JSPComponentItem.java:224)
    at com.sapportals.portal.prt.core.broker.JSPComponentItem.getComponentInstance(JSPComponentItem.java:86)
    at com.sapportals.portal.prt.core.broker.PortalComponentItemFacade.service(PortalComponentItemFacade.java:338)
    at com.sapportals.portal.prt.core.broker.PortalComponentItem.service(PortalComponentItem.java:817)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:385)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:462)
    at com.sapportals.portal.prt.component.AbstractComponentResponse.include(AbstractComponentResponse.java:88)
    at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:226)
    at com.sapportals.portal.htmlb.page.JSPDynPage.doOutput(JSPDynPage.java:76)
    at com.sapportals.htmlb.page.PageProcessor.handleRequest(PageProcessor.java:109)
    at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.java:135)
    at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)
    at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)
    at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:300)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:190)
    at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:209)
    at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:576)
    at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:300)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:190)
    at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:669)
    at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:208)
    at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:532)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:415)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.inqmy.services.servlets_jsp.server.InvokerServlet.service(InvokerServlet.java:126)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.inqmy.services.servlets_jsp.server.RunServlet.runSerlvet(RunServlet.java:149)
    at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl.java:833)
    at com.inqmy.services.httpserver.server.RequestAnalizer.checkFilename(RequestAnalizer.java:665)
    at com.inqmy.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:312)
    at com.inqmy.services.httpserver.server.Response.handle(Response.java:173)
    at com.inqmy.services.httpserver.server.HttpServerFrame.request(HttpServerFrame.java:1229)
    at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:36)
    at com.inqmy.core.cluster.impl5.ParserRunner.run(ParserRunner.java:55)
    at com.inqmy.core.thread.impl0.ActionObject.run(ActionObject.java:46)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.inqmy.core.thread.impl0.SingleThread.run(SingleThread.java:148)
    Caused by: com.sapportals.portal.prt.servlets_jsp.server.compiler.CompilingException: D:/usr/sap/EPD1/j2ee/j2ee_22/cluster/server/services/servlet_jsp/work/jspTemp/irj/root/WEB-INF/portal/portalapps/CustomerSearch/work/pagelet/_sapportalsjsp_TableView.java:39: cannot resolve symbol
    symbol : class MyBean
    location: package TableViewExample
    TableViewExample.MyBean myBeanName = null;
    ^
    D:/usr/sap/EPD1/j2ee/j2ee_22/cluster/server/services/servlet_jsp/work/jspTemp/irj/root/WEB-INF/portal/portalapps/CustomerSearch/work/pagelet/_sapportalsjsp_TableView.java:41: cannot resolve symbol
    symbol : class MyBean
    location: package TableViewExample
    myBeanName = (TableViewExample.MyBean)pageContext.getAttribute("myBeanName", PageContext.APPLICATION_SCOPE);
    ^
    D:/usr/sap/EPD1/j2ee/j2ee_22/cluster/server/services/servlet_jsp/work/jspTemp/irj/root/WEB-INF/portal/portalapps/CustomerSearch/work/pagelet/_sapportalsjsp_TableView.java:45: cannot resolve symbol
    symbol : class MyBean
    location: package TableViewExample
    myBeanName = (TableViewExample.MyBean) Beans.instantiate(this.getClass().getClassLoader(), "TableViewExample.MyBean");
    ^
    3 errors
    at com.sapportals.portal.prt.servlets_jsp.server.compiler.JavaCompiler.compileExternal(JavaCompiler.java:439)
    at com.sapportals.portal.prt.servlets_jsp.server.compiler.JavaCompiler.compile(JavaCompiler.java:539)
    at com.sapportals.portal.prt.servlets_jsp.server.jsp.JSPParser.parse(JSPParser.java:2140)
    at com.sapportals.portal.prt.servlets_jsp.server.jsp.JSPCompiler.compile(JSPCompiler.java:76)
    at com.sapportals.portal.prt.servlets_jsp.server.jsp.JSPCompiler.run(JSPCompiler.java:118)
    at com.sapportals.portal.prt.core.broker.JSPComponentItem.compileJSP(JSPComponentItem.java:224)
    at com.sapportals.portal.prt.core.broker.JSPComponentItem.getComponentInstance(JSPComponentItem.java:86)
    at com.sapportals.portal.prt.core.broker.PortalComponentItemFacade.service(PortalComponentItemFacade.java:338)
    at com.sapportals.portal.prt.core.broker.PortalComponentItem.service(PortalComponentItem.java:817)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:385)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:462)
    at com.sapportals.portal.prt.component.AbstractComponentResponse.include(AbstractComponentResponse.java:88)
    at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:226)
    at com.sapportals.portal.htmlb.page.JSPDynPage.doOutput(JSPDynPage.java:76)
    at com.sapportals.htmlb.page.PageProcessor.handleRequest(PageProcessor.java:109)
    at com.sapportals.portal.htmlb.page.PageProcessorComponent.doContent(PageProcessorComponent.java:135)
    at com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:209)
    at com.sapportals.portal.prt.component.AbstractPortalComponent.service(AbstractPortalComponent.java:114)
    at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:300)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:190)
    at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:209)
    at com.sapportals.portal.prt.pom.PortalNode.service(PortalNode.java:576)
    at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:300)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:138)
    at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:190)
    at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:669)
    at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:208)
    at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:532)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:415)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.inqmy.services.servlets_jsp.server.InvokerServlet.service(InvokerServlet.java:126)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    at com.inqmy.services.servlets_jsp.server.RunServlet.runSerlvet(RunServlet.java:149)
    at com.inqmy.services.servlets_jsp.server.ServletsAndJspImpl.startServlet(ServletsAndJspImpl.java:833)
    at com.inqmy.services.httpserver.server.RequestAnalizer.checkFilename(RequestAnalizer.java:665)
    at com.inqmy.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:312)
    at com.inqmy.services.httpserver.server.Response.handle(Response.java:173)
    at com.inqmy.services.httpserver.server.HttpServerFrame.request(HttpServerFrame.java:1229)
    at com.inqmy.core.service.context.container.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:36)
    at com.inqmy.core.cluster.impl5.ParserRunner.run(ParserRunner.java:55)
    at com.inqmy.core.thread.impl0.ActionObject.run(ActionObject.java:46)
    at java.security.AccessController.doPrivileged(Native Method)
    at com.inqmy.core.thread.impl0.SingleThread.run(SingleThread.java:148)
    [email protected]7 #
    TableViewExample.java Code
    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.ResultSet;
    import java.sql.ResultSetMetaData;
    import java.sql.SQLException;
    import java.sql.Statement;
    import java.util.Vector;
    import com.sapportals.htmlb.InputField;
    import com.sapportals.htmlb.event.Event;
    import com.sapportals.htmlb.event.TableNavigationEvent;
    import com.sapportals.htmlb.page.DynPage;
    import com.sapportals.htmlb.page.PageException;
    import com.sapportals.htmlb.table.DefaultTableViewModel;
    import com.sapportals.htmlb.table.TableView;
    import com.sapportals.htmlb.table.TableViewModel;
    import com.sapportals.portal.htmlb.page.JSPDynPage;
    import com.sapportals.portal.htmlb.page.PageProcessorComponent;
    import com.sapportals.portal.prt.component.*;
    public class TableViewExample extends PageProcessorComponent
         /* (non-Javadoc)
    @see com.sapportals.portal.htmlb.page.PageProcessorComponent#getPage()
         public DynPage getPage()
              return new MyDynPage();
         public class MyDynPage extends JSPDynPage
              //variables
              private int visibleRow = 1;
              public String search;
              public String state = "0";
              MyBean myBean;
              /* (non-Javadoc)
    @see com.sapportals.htmlb.page.DynPage#doInitialization()
              //Get Context and Initialize Bean
              public void doInitialization() throws PageException
                   IPortalComponentRequest request = (IPortalComponentRequest) this.getRequest();
                   IPortalComponentContext myContext = request.getComponentContext();
                   IPortalComponentProfile myProfile = myContext.getProfile();
                   IPortalComponentProfile userProfile = request.getComponentContext().getProfile();
                   MyBean myBean = new MyBean();
                   myBean.setText("");
                   myProfile.putValue("myBeanName", myBean);
              /* (non-Javadoc)
    @see com.sapportals.htmlb.page.DynPage#doProcessAfterInput()
               //Called Directly After The Data Was Submitted
              public void doProcessAfterInput() throws PageException
                   //Get the Bean Object
                   IPortalComponentRequest request = (IPortalComponentRequest) this.getRequest();
                   IPortalComponentContext context = request.getComponentContext();
                   IPortalComponentProfile profile = context.getProfile();
                   //Get the Account Info Input Field
                   InputField myInputField = (InputField) getComponentByName("account_input");
                   if( myInputField != null )
                        search = myInputField.getValueAsDataType().toString();
                   myBean = (MyBean) profile.getValue("myBeanName");
                   myBean.setAccount(search);
                   myBean.MyBeanModel();
                   state = myBean.state;
                   if( state == "1" )
                        //get the selected row / rows
                        //get the tableView by getComponentByName
                        TableView table = (TableView) this.getComponentByName("myTableView");
                        //Get the first visible row
                        int firstVisibleRow = table.getVisibleFirstRow();
                        //Get the last visible row
                        int lastVisibleRow = table.getVisibleLastRow();
                        //which of the visible rows was selected
                        StringBuffer strBuff = new StringBuffer();
                        for( int i = firstVisibleRow; i <= lastVisibleRow; i++ )
                             if( table.isRowSelected(i) )
                                  strBuff.append("Row: " + i + " : ");
              /* (non-Javadoc)
    @see com.sapportals.htmlb.page.DynPage#doProcessBeforeOutput()
              //Called Directly Before Output - Last Called Function
              public void doProcessBeforeOutput() throws PageException
                   //set the jsp to load
                   this.setJspName("TableView.jsp");
              //Called If The Navigation Event Was Send
              //The JSP has set the navigation mode byline so the user can navigate
              //line by line, page up and down, first and last entry
              public void onNavigation(Event event)
                   if( state == "1" )
                        //Navigation - get the event to recover the actual position
                        TableNavigationEvent tne = (TableNavigationEvent) event;
                        //With the event the method getFirstVariableRowAfter() can be used
                        //which gives the acutal position (after the event)
                        this.visibleRow = tne.getFirstVisibleRowAfter();
                        if( myBean != null )
                             //just for the first time, when there is no bean
                             //set the new visibleRow
                             myBean.setVisibleRow(new Integer(this.visibleRow).toString());
              public void onSendButtonClicked(Event event) throws PageException
                   IPortalComponentRequest request = (IPortalComponentRequest) this.getRequest();
                   IPortalComponentContext context = request.getComponentContext();
                   IPortalComponentProfile myProfile = context.getProfile();
                   IPortalComponentProfile userProfile = request.getComponentContext().getProfile();
                   myBean = (MyBean) myProfile.getValue("myBeanName");
                   state = "1";
                   myBean.setState("1");
                   myProfile.putValue("myBeanName", myBean);
         public class MyBean
              //Properties
              public DefaultTableViewModel model;
              private String visibleRow = "1";
              private String text;
              private String account;
              private String state = "0";
              private String searchType;
              //get/set account
              public void setAccount(String account)
                   this.account = account;
              public String getAccount()
                   return this.account;
              //get/set state
              public void setState(String state)
                   this.state = state;
              public String getState()
                   return this.state;
              //get/set model
              public void setModel(DefaultTableViewModel model)
                   this.model = model;
              public TableViewModel getModel()
                   return this.model;
              //get/set Text for status messages
              public void setText(String text)
                   this.text = text;
              public String getText()
                   return this.text;
              //get/set VisibleRow for tableView
              public void setVisibleRow(String visibleRow)
                   this.visibleRow = visibleRow;
              public String getVisibleRow()
                   return this.visibleRow;
              //get/set SearchType
              public void setSearchType(String searchType)
                   this.searchType = searchType;
              public String getSearchType()
                   return this.searchType;
              //Create Table View Model
              public void MyBeanModel()
                   model = this.createNewTable(model);
                   //Set Table Text
                   if( model.getRowCount() > 0 )
                        this.setText("Customer Information Found For: " + this.getSearchType());
                   else
                        this.setText("No Records Found For Account: " + this.getAccount());
              //Create Data For A DefaultTableViewModel By Using Vector
              private DefaultTableViewModel createNewTable(DefaultTableViewModel model)
                   //Get a vector with a filled up data array
                   Vector data = null;
                   try
                        data = doGet();     
                   catch( ClassNotFoundException e )
                        e.printStackTrace();
                   //Get a new vector for the titles
                   Vector colName = new Vector();
                   colName.addElement("NUMBER");
                   colName.addElement("CUSTOMER NAME");
                   colName.addElement("PHONE");
                   colName.addElement("STREET");
                   colName.addElement("CITY");
                   colName.addElement("STATE");
                   colName.addElement("ZIP");
                   model = new DefaultTableViewModel(data, colName);
                   return model;
              //Method will execute SQL string with search parameter on the database
              public Vector doGet() throws ClassNotFoundException
                   Statement stmt = null;
                   Vector myVector = new Vector();
                   try
                        //Load the sun jdbc-odbc bridge driver
                        DriverManager.registerDriver (new oracle.jdbc.OracleDriver());
                        String dbUrl = "jdbc:oracle:oci8:@testX003";
                        Connection con = DriverManager.getConnection(dbUrl, "test", "test");
                        //Create a statement to submit SQL statements to the driver
                        stmt = con.createStatement();
                        String query = "select PAYER_NUM, PAYER_CUST_NAME, PAYER_PHONE_NUM_1 " +
                                          "PAYER_STR_ADDR, PAYER_CITY_NAME, PAYER_ST_ABBR, PAYER_ZIP_CD " +
                                          "from CUST_PAYER where PAYER_NUM = " + this.getAccount() + "";
                        this.setSearchType("Payer Search");
                        ResultSet rs;
                        rs = stmt.executeQuery(query);
                        ResultSetMetaData rsmd = rs.getMetaData();
                        //Get number of columns
                        int numCols = rsmd.getColumnCount();
                        if( numCols == 0 )
                             query = "select SLDTO_NUM, SLDTO_CUST_NAME, SLDTO_PHONE_NUM_1 " +
                                       "SLDTO_STR_ADDR, SLDTO_CITY_NAME, SLDTO_ST_ABBR, SLDTO_ZIP_CD " +
                                       "from CUST_PAYER where SLDTO_NUM = " + this.getAccount() + "";
                             this.setSearchType("SoldTo Search");
                             rs = stmt.executeQuery(query);
                        myVector = createData(rs);
                        //Close ResultSet
                        rs.close();
                        //Close Statement
                        stmt.close();
                        //Close Connection
                        con.close();
                   catch( SQLException ex)
                        this.account = ex.getMessage();
                   return myVector;
              //This method pulls the database selection results and places them into vectors
              private Vector createData(ResultSet res) throws SQLException
                   //Get the metadata infro
                   ResultSetMetaData rsmd = res.getMetaData();
                   //Get number of columns
                   int numCols = rsmd.getColumnCount();
                   String checkVal;
                   //Loop through the result set and load rows of data into Vector
                   Vector dataVec = new Vector();
                   Vector retVector = new Vector();
                   int k = 0;
                   while( res.next() )
                        k++;
                        for( int i = 1; i

    Hi Bernhard,
    nice to hear that we resolve the problem
    > Karstens answer solved my base problem,
    > Detlevs answer lead into the right direction.
    Not that I've that need for points...
    It's just the question why my answer (if you follow the link, my answer was: delete two lines, from which one is essential to be deleted) only "lead into the right direction"... In fact, it solved the base problem, I would claim for me
    To give the technical background: If your write
    <property name="ComponentType" value="jspnative"/>
    the portal runtime expects a component consisting of a native JSP; the second directive -
    <property name="JSP" value="pagelet/InitialPage.jsp"/>
    - for this case tells where to find this JSP. So if you delete the first line, <i>at least</i> the second line has no sense anymore. To clean up such a portalapp.xml, it just makes sense also to delete the second line.
    Best regards
    Detlev

  • SAP J2EE Engine has stopped working suddenly

    Hi,
    I have only SAP J2EE stack in WebAs installed on a machine couple of months ago and all the while it was working fine.But suddenly one day (precisely monday)i see that  J2EE Server node is not starting up. But the central instance (which has processes MsgServer.exe,Enserver.exe) has started sucessfully but not the server node instance.
    I am getting the following error in the log file
    <-- Error log message starts here----
    >
    [Thr 3108] Tue Nov 15 11:53:06 2005
    [Thr 3108] *** ERROR => invalid return code of process [bootstrap] (exitcode=66) [jstartxx.c   1433]
    [Thr 3108] JControlExecuteBootstrap: error executing bootstrap node [bootstrap] (rc=66)
    [Thr 3108] JControlCloseProgram: started (exitcode = 66)
    [Thr 3108] JControlCloseProgram: good bye... (exitcode=66)
    <-- Error log message starts here----
    >
    <- Trace error message starts here-->
    #1.5#000E0C6021FB00000000001200000614000405862C538277#1131973734265#com.sap.sql.jdbc.NativeConnectionFactory##com.sap.sql.jdbc.NativeConnectionFactory#######Thread[Thread-1,5,main]##0#0#Error#1#/System/Database/sql/jdbc#Java#com.sap.sql_0002##SQL error occurred on connection jdbc:datadirect:sqlserver://blrkecsaptst1:1433;databasename=J2E: code=18,456, state="28000", message="[DataDirect][SQLServer JDBC Driver][SQLServer]Login failed for user 'SAPJ2EDB'.
    => (0,08001,[DataDirect][SQLServer JDBC Driver]An error occurred while attempting to log onto the database.)".#5#18456#28000#[DataDirect][SQLServer JDBC Driver][SQLServer]Login failed for user 'SAPJ2EDB'.
    => (0,08001,[DataDirect][SQLServer JDBC Driver]An error occurred while attempting to log onto the database.)#jdbc:datadirect:sqlserver://blrkecsaptst1:1433;databasename=J2E#<null>#
    #1.5#000E0C6021FB00000000001300000614000405862C5392D1#1131973734265#com.sap.sql.jdbc.NativeConnectionFactory##com.sap.sql.jdbc.NativeConnectionFactory#######Thread[Thread-1,5,main]##0#0#Error##Plain###java.sql.SQLException: [DataDirect][SQLServer JDBC Driver][SQLServer]Login failed for user 'SAPJ2EDB'.
         at com.ddtek.jdbc.base.BaseExceptions.createException(Unknown Source)
         at com.ddtek.jdbc.base.BaseExceptions.getException(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSLoginRequest.processReplyToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown Source)
         at com.ddtek.jdbc.sqlserver.SQLServerImplConnection.open(Unknown Source)
         at com.ddtek.jdbc.base.BaseConnection.connect(Unknown Source)
         at com.ddtek.jdbc.base.BaseConnection.setupImplConnection(Unknown Source)
         at com.ddtek.jdbc.base.BaseConnection.open(Unknown Source)
         at com.ddtek.jdbc.base.BaseDriver.connect(Unknown Source)
         at com.sap.sql.jdbc.NativeConnectionFactory.createNativeConnection(NativeConnectionFactory.java:219)
         at com.sap.sql.connect.OpenSQLDataSourceImpl.createPooledConnection(OpenSQLDataSourceImpl.java:570)
         at com.sap.sql.connect.OpenSQLDataSourceImpl.getPooledConnection(OpenSQLDataSourceImpl.java:263)
         at com.sap.engine.core.configuration.impl.persistence.rdbms.DBConnectionPool.createConnection(DBConnectionPool.java:294)
         at com.sap.engine.core.configuration.impl.persistence.rdbms.DBConnectionPool.<init>(DBConnectionPool.java:123)
         at com.sap.engine.core.configuration.impl.persistence.rdbms.PersistenceHandler.<init>(PersistenceHandler.java:38)
         at com.sap.engine.core.configuration.impl.cache.ConfigurationCache.<init>(ConfigurationCache.java:147)
         at com.sap.engine.core.configuration.impl.ConfigurationHandlerFactoryImpl.<init>(ConfigurationHandlerFactoryImpl.java:30)
         at com.sap.engine.core.configuration.impl0.ConfigurationManagerImpl.initInternal(ConfigurationManagerImpl.java:180)
         at com.sap.engine.core.configuration.AbstractConfigurationManagerImpl.init(AbstractConfigurationManagerImpl.java:170)
         at com.sap.engine.core.Framework.loadSingleManager(Framework.java:396)
         at com.sap.engine.core.Framework.loadManagers(Framework.java:163)
         at com.sap.engine.core.Framework.start(Framework.java:97)
         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:324)
         at com.sap.engine.boot.FrameThread.run(FrameThread.java:58)
         at java.lang.Thread.run(Thread.java:534)
    #1.5#000E0C6021FB00000000001500000614000405862C53DC14#1131973734281#com.sap.engine.core.configuration##com.sap.engine.core.configuration#######Thread[Thread-1,5,main]##0#0#Error#1#/System/Server#Plain###Error while connecting to DB.
    =======================================================
    com.sap.engine.frame.core.configuration.ConfigurationException: Error while connecting to DB.
         at com.sap.engine.core.configuration.impl.persistence.rdbms.DBConnectionPool.createConnection(DBConnectionPool.java:344)
         at com.sap.engine.core.configuration.impl.persistence.rdbms.DBConnectionPool.<init>(DBConnectionPool.java:123)
         at com.sap.engine.core.configuration.impl.persistence.rdbms.PersistenceHandler.<init>(PersistenceHandler.java:38)
         at com.sap.engine.core.configuration.impl.cache.ConfigurationCache.<init>(ConfigurationCache.java:147)
         at com.sap.engine.core.configuration.impl.ConfigurationHandlerFactoryImpl.<init>(ConfigurationHandlerFactoryImpl.java:30)
         at com.sap.engine.core.configuration.impl0.ConfigurationManagerImpl.initInternal(ConfigurationManagerImpl.java:180)
         at com.sap.engine.core.configuration.AbstractConfigurationManagerImpl.init(AbstractConfigurationManagerImpl.java:170)
         at com.sap.engine.core.Framework.loadSingleManager(Framework.java:396)
         at com.sap.engine.core.Framework.loadManagers(Framework.java:163)
         at com.sap.engine.core.Framework.start(Framework.java:97)
         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:324)
         at com.sap.engine.boot.FrameThread.run(FrameThread.java:58)
         at java.lang.Thread.run(Thread.java:534)
    Caused by: java.sql.SQLException: [DataDirect][SQLServer JDBC Driver][SQLServer]Login failed for user 'SAPJ2EDB'.
         at com.ddtek.jdbc.base.BaseExceptions.createException(Unknown Source)
         at com.ddtek.jdbc.base.BaseExceptions.getException(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSLoginRequest.processReplyToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown Source)
         at com.ddtek.jdbc.sqlserver.SQLServerImplConnection.open(Unknown Source)
         at com.ddtek.jdbc.base.BaseConnection.connect(Unknown Source)
         at com.ddtek.jdbc.base.BaseConnection.setupImplConnection(Unknown Source)
         at com.ddtek.jdbc.base.BaseConnection.open(Unknown Source)
         at com.ddtek.jdbc.base.BaseDriver.connect(Unknown Source)
         at com.sap.sql.jdbc.NativeConnectionFactory.createNativeConnection(NativeConnectionFactory.java:219)
         at com.sap.sql.connect.OpenSQLDataSourceImpl.createPooledConnection(OpenSQLDataSourceImpl.java:570)
         at com.sap.sql.connect.OpenSQLDataSourceImpl.getPooledConnection(OpenSQLDataSourceImpl.java:263)
         at com.sap.engine.core.configuration.impl.persistence.rdbms.DBConnectionPool.createConnection(DBConnectionPool.java:294)
         ... 15 more
    #1.5#000E0C6021FB00020000000000000614000405862C5494F7#1131973734328#com.sap.engine.core.cluster.impl6.JoinPortListener##com.sap.engine.core.cluster.impl6.JoinPortListener.run()#######SAPEngine_Application_Thread[impl:3]_32##0#0#Error##Plain###java.lang.NullPointerException#
    #1.5#000E0C6021FB00020000000100000614000405862C5497CD#1131973734328#com.sap.engine.core.cluster.impl6.JoinPortListener##com.sap.engine.core.cluster.impl6.JoinPortListener.run()#######SAPEngine_Application_Thread[impl:3]_32##0#0#Error##Plain###java.lang.NullPointerException
         at com.sap.engine.core.cluster.impl6.ClusterManagerImpl.getClusterMonitor(ClusterManagerImpl.java:2254)
         at com.sap.engine.core.cluster.impl6.JoinPortListener.waitForThisElementConstruction(JoinPortListener.java:120)
         at com.sap.engine.core.cluster.impl6.JoinPortListener.access$000(JoinPortListener.java:30)
         at com.sap.engine.core.cluster.impl6.JoinPortListener$SocketProcessor.run(JoinPortListener.java:137)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:94)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:162)
    <--Trace error message ends here--->
    I have't not changed any passwords of db users like SAPJ2EDB but i don't know why i am getting this error suddenly.
    Can anyone throw light on this issue.
    Thanks and Regards,
    Satish

    Hi Detlev,
    The DB (SQL 2000) is started and i have verified through
    Window service console and SQL Server Service Manager.
    Even the Config tool (i.e offline tool) is throwing the following error message when started.
    ""PATHHASH" = ?#
    #1.5#C000AC19E95B000100000008008420AE0004059711CA16E0#1132046303500#/System/Server##com.sap.engine.core.configuration#######Thread[AWT-EventQueue-0,6,main]##0#0#Error#1#com.sap.engine.core.configuration#Plain###[DataDirect][SQLServer JDBC Driver][SQLServer]Invalid object name 'J2EE_CONFIG'.
    =======================================================
    java.sql.SQLException: [DataDirect][SQLServer JDBC Driver][SQLServer]Invalid object name 'J2EE_CONFIG'.
         at com.ddtek.jdbc.base.BaseExceptions.createException(Unknown Source)
         at com.ddtek.jdbc.base.BaseExceptions.getException(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRPCRequest.processReplyToken(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRPCNonCursorExecuteRequest.submitPrepare(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRPCExecuteRequest.doPrepExec(Unknown Source)
         at com.ddtek.jdbc.sqlserver.tds.TDSRPCExecuteRequest.execute(Unknown Source)
         at com.ddtek.jdbc.sqlserver.SQLServerImplStatement.execute(Unknown Source)
         at com.ddtek.jdbc.base.BaseStatement.commonExecute(Unknown Source)
         at com.ddtek.jdbc.base.BaseStatement.executeQueryInternal(Unknown Source)
         at com.ddtek.jdbc.base.BasePreparedStatement.executeQuery(Unknown Source)
         at com.sap.sql.jdbc.basic.BasicPreparedStatement.executeQuery(BasicPreparedStatement.java:97)
         at com.sap.sql.jdbc.direct.DirectPreparedStatement.executeQuery(DirectPreparedStatement.java:270)
         at com.sap.sql.jdbc.direct.DirectPreparedStatement.executeQuery(DirectPreparedStatement.java:241)
         at com.sap.engine.core.configuration.impl.persistence.rdbms.DBAccessDefault.getConfiguration(DBAccessDefault.java:578)
         at com.sap.engine.core.configuration.impl.persistence.rdbms.PersistenceHandler.readConfig(PersistenceHandler.java:102)
         at com.sap.engine.core.configuration.impl.cache.CachedConfiguration.<init>(CachedConfiguration.java:62)
         at com.sap.engine.core.configuration.impl.cache.ConfigurationCache.getCachedConfiguration(ConfigurationCache.java:879)
         at com.sap.engine.core.configuration.impl.cache.ConfigurationCache.getCachedConfiguration(ConfigurationCache.java:913)
         at com.sap.engine.core.configuration.impl.cache.ConfigurationCache.openConfiguration(ConfigurationCache.java:783)
         at com.sap.engine.core.configuration.impl.ConfigurationHandlerImpl.openConfiguration(ConfigurationHandlerImpl.java:694)
         at com.sap.engine.configtool.batch.Scanner.scan(Scanner.java:44)
         at com.sap.engine.configtool.visual.ConfigTool.loadClusterData(ConfigTool.java:100)
         at com.sap.engine.configtool.visual.ConfigTool.initScan(ConfigTool.java:86)
         at com.sap.engine.configtool.visual.ConfigTool.scanAction(ConfigTool.java:237)
         at com.sap.engine.configtool.visual.ConfigTool.actionPerformed(ConfigTool.java:209)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1786)
         at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
         at javax.swing.AbstractButton.doClick(AbstractButton.java:289)
         at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1113)
         at javax.swing.plaf.basic.BasicMenuItemUI$MouseInputHandler.mouseReleased(BasicMenuItemUI.java:943)
         at java.awt.Component.processMouseEvent(Component.java:5100)
         at java.awt.Component.processEvent(Component.java:4897)
         at java.awt.Container.processEvent(Container.java:1569)
         at java.awt.Component.dispatchEventImpl(Component.java:3615)
         at java.awt.Container.dispatchEventImpl(Container.java:1627)
         at java.awt.Component.dispatchEvent(Component.java:3477)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
         at java.awt.Container.dispatchEventImpl(Container.java:1613)
         at java.awt.Window.dispatchEventImpl(Window.java:1606)
         at java.awt.Component.dispatchEvent(Component.java:3477)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
    #1.5#C000AC19E95B000100000009008420AE0004059711CA16E0#1132046303500#/System/Logging##com.sap.tc.logging.FileLog.[setFormatter()]#######Thread[AWT-EventQueue-0,6,main]##0#0#Warning##Java#SAP_LOGGING_FORMATTER_ERROR##Trying to change a formatter on active log ! The reset() method must be first called!#1#.
    system.log#
    #1.5#C000AC19E95B00010000000A008420AE0004059711CA5178#1132046303515#/System/Server##com.sap.engine.core.configuration#######Thread[AWT-EventQueue-0,6,main]##0#0#Info#1#com.sap.engine.core.configuration#Plain###Properties for connect through secure store not set. Please check your connect properties. Trying to connect via plain user/password.#
    #1.5#C000AC19E95B00010000000B008420AE0004059711CA5178#1132046303515#/System/Database/sql/jdbc##com.sap.sql.jdbc.NativeConnectionFactory#######Thread[AWT-EventQueue-0,6,main]##0#0#Error#1#com.sap.sql.jdbc.NativeConnectionFactory#Java#com.sap.sql_0015#com.sap.sql.log.OpenSQLResourceBundle#Value "" is not allowed for parameter .#2#url##
    1)is it due to mismatch of the passwords of the user SAPJ2EDB in database and J2EE Engine and Securestore of config tool
    2)is there some DB related problem ?
    3)i think the problem is similar to this one
    Netweaver's WebAS SDM process goes corrupt, exitcode=66
    But the solution there is not so clear
    4)After i changed the password both in the database as well as in configtool >Secure Tool>/jdbc/pool/J2E/password..but i am getting java.sql.SQLException: [DataDirect][SQLServer JDBC Driver][SQLServer]Invalid object name 'J2EE_CONFIG' this error.
    Any idea on what needs to be done to fix this problem
    Regards,
    Satish

  • Confusion about get/set method not working

    Hi
    Hopefully someone can point out the elementary mistake I have made in my code. I have created a get/set method to hold a value"total" so that I can then get it to display it further down my code in an HTML page. I am setting the value as I can check this by printing it out (line 102) but when I try to use it again it displays 0.0. What have I done wrong?
    class ReportListener implements ActionListener
         Context context;
         ResultSet resultAll;
         ResultSet resultTotal;
         JFrame frame;
         int daysInMonth;
         int i;
         DisplayCurrencyOnBills d;
         DateFormatSymbols symbols;
         String[] newWeekday;
         Date theDate;
         String date;
         ReportListener (Context theContext)
              context = theContext;
         public void actionPerformed(ActionEvent e)
           try
              printWeeklyReport();
              //countDaysInMonth();
              getReportMoneyTotal();
         catch (SQLException s)
                   s.printStackTrace();
         public void countDaysInMonth()
         public void getReportMoneyTotal() throws SQLException
              Calendar todayTotal =Calendar.getInstance() ;
               SimpleDateFormat reportDateFormat = new SimpleDateFormat("dd MM yyyy");
              PreparedStatement preparedT =context.getConnection().prepareStatement(
                   "SELECT Sum(tblSession.Fee) AS Total, Count(tblBooking.BookingID) AS CountOfBookingID FROM tblSession INNER JOIN "+
                   "(tblBooking INNER JOIN tblCustomer_Booking ON tblBooking.BookingID = tblCustomer_Booking.BookingID) ON tblSession.SessionID = tblBooking.SessionID "+
                   "WHERE (((tblBooking.EventDate)>DateAdd('m',-1,#"+reportDateFormat.format(todayTotal.getTime())+"#)) AND ((tblSession.Session)='Morning' Or (tblSession.Session)='Evening')) OR (((tblSession.Session)='Afternoon') AND ((tblBooking.Extension)=Yes))"
              ResultSet resultTotal =preparedT.executeQuery();
              resultTotal.next();
              double total =resultTotal.getDouble("Total");     
              context.setReportIncomeTotal(total);
              System.out.println("Line 102 "+context.getReportIncomeTotal());
              preparedT.close();
         public void printWeeklyReport() throws SQLException
              Calendar today =Calendar.getInstance() ;
               SimpleDateFormat reportDateFormat = new SimpleDateFormat("dd MM yyyy");
              PreparedStatement prepared =context.getConnection().prepareStatement(
                   "SELECT tblBooking.EventDate, tblSession.Session, tblBooking.Extension, tblSession.Fee, Count(tblBooking.BookingID) AS CountOfBookingID "+
                   "FROM tblSession INNER JOIN (tblBooking INNER JOIN tblCustomer_Booking ON tblBooking.BookingID = tblCustomer_Booking.BookingID) ON "+
                   "tblSession.SessionID = tblBooking.SessionID GROUP BY tblBooking.EventDate, tblSession.Session, tblBooking.Extension, tblSession.Fee "+
                   "HAVING (((tblBooking.EventDate)>DateAdd('m',-1,#"+reportDateFormat.format(today.getTime())+"#)) AND ((tblSession.Session)='Morning' Or "+
                   "(tblSession.Session)='Evening')) OR (((tblSession.Session)='Afternoon') AND ((tblBooking.Extension)=Yes))"
              ResultSet resultAll =prepared.executeQuery();
              resultAll.next();
              System.out.println("Line 123 "+context.getReportIncomeTotal());
                        PrintWriter printWriter;
                        try
                             JFileChooser fc=new JFileChooser();
                             int returnVal = fc.showSaveDialog(frame);
                             if (returnVal != JFileChooser.APPROVE_OPTION)
                                  return;
                             FileOutputStream outputStream=
                                  new FileOutputStream(fc.getSelectedFile());
                             OutputStreamWriter writer=
                                  new OutputStreamWriter(outputStream,"UTF-8");
                             printWriter=new PrintWriter(writer);     
                           printWriter.println("<html><meta http-equiv='Content-Type' content='text/html; charset=UTF-8'><body><h1>Monthly Usage Statistics</h1>");
                           printWriter.println("<table width='100%' border='1'><tr><td width='100%' colspan='8'><h2 align='center'>Monthly Summary</h2></td></tr>");
                         System.out.println("Line 152 "+context.getReportIncomeTotal());
                         int count = 0;
                             while ( resultAll.next() )
                              count++;
                              String session = resultAll.getString("Session");
                              Double fee= resultAll.getDouble("Fee");
                           // display currency correctly
                         //double d=Double.parseDouble(fee);
                         Locale locale = new Locale("GBP");
                         NumberFormat gbpFormat = NumberFormat.getCurrencyInstance(locale);
                             symbols = new DateFormatSymbols(new Locale("en"));
                         newWeekday =symbols.getWeekdays();
                             SimpleDateFormat formatter = new SimpleDateFormat("EEEE",symbols);
                             Date theEventDate = new Date();
                             theEventDate=resultAll.getDate("EventDate");
                             date = formatter.format(theEventDate);
                             // set date for Usage Report
                             Calendar reportDate = Calendar.getInstance();
                             Calendar reportToday =Calendar.getInstance();
                             reportDate.add(Calendar.MONTH,-1);
                             SimpleDateFormat reportFormat = new SimpleDateFormat("EEEE ,dd MMM yyy");     
                             //setDecimalFormat for report total
                             DecimalFormat decFormat = new DecimalFormat(".##");
                             printWriter.println(
                             "<tr><td width='100%' colspan='8'>For month from "+reportFormat.format(reportDate.getTime())+" to "+reportFormat.format(reportToday.getTime())+"</td></tr><tr><td width='100%' colspan='8'>Total amount of income from occasional bookings "+decFormat.format(context.getReportIncomeTotal())+"</td>"+
                               "</tr><tr><td width='100%' colspan='8'>Percentage use for all bookings</td></tr><tr><td width='8%'></td><td width='8%'>MON</td><td width='9%'>TUES</td>"+
                            "<td width='9%'>WEDS</td><td width='9%'>THURS</td><td width='9%'>FRI</td><td width='9%'>SAT</td><td width='9%'>SUN</td></tr><tr><td width='8%'>AM</td><td width='8%'></td>"+
                            "<td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td></tr><tr><td width='8%'>PM</td><td width='8%'></td>"+
                            "<td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td></tr><tr><td width='8%'>EVE</td><td width='8%'></td>"+
                            "<td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td><td width='9%'></td></tr>"
                             System.out.println(count);
                             printWriter.println("</table>");
                             printWriter.println("</body></html>");
                             printWriter.close();
                             prepared.close();
                             JDialog reportDialog=new JDialog(frame);
                             reportDialog.setSize(800,600);
                             JEditorPane editorPane=new JEditorPane(fc.getSelectedFile().toURL());
                             editorPane.setContentType("text/html; charset=UTF-8");
                             reportDialog.getContentPane().add(editorPane);
                             reportDialog.setVisible(true);
                        catch (IOException exception)
                             exception.printStackTrace();
         This code finds data from a database(this works as it also prints a report). Here is the extraxt of my get/set method which is located in a "context" class.
    public void setReportIncomeTotal(double total)
              this.total=total;
         public double getReportIncomeTotal()
              return total;
         }I'd be grateful for any help.

    but when I try to use it again it displays 0.0This seems to mean that either the value has been reset or you are calling the method on another (new) ReportListener.
    It's hard to say, as you didn't provide us with the code sample that illustrate the corresponding scenario (did you?.)
    Note that I didn't get into details, but I just noticed that your actionPerformed method first print weekly report, and then get the money total. (Shouldn't it be the opposite order?)

Maybe you are looking for

  • Using LaserJet 6L & Belkin parallel adapter

    I have a HP LaserJet 6L printer (circa 1998) which I now want to use with my Powerbook. I have a Belkin USB->parallel adapter (model F5U002) of similar vintage. I connected the printer to my powerbook with the adapter cable and nothing happened. I we

  • JPQL - No UPPER() in ORDER BY clause??

    I have created a NamedQuery and am attempting to order my returned collection using the ORDER BY clause, however, the specification asks for string ordering to be case insensitive. It seems that I cannot do that with the Java Persistence Query Langua

  • Something strange happening with my fonts

    Hi there, Please see the link to this pdf. http://mssociety.ca/bc/pdf/2012_Footnotes_1_print.pdf The PDF is supposed to have all the fonts embedded, but page 1 is showing up wonky - sometimes. Some of the fonts on page 1 are incorrect. They should al

  • Input field in dialog screen

    Hi all, I need to create an input field on screen, which would enable input not by writing but by selecting a value from a list. I tried to define the field as a listbox, but the FM VRM_SET_VALUES used for populating the values can contain only 2 fie

  • Persistent HTTP Requests in BSP: Can you Flush the Response without Ending It?

    Hello all, I have been looking for a way to implement a persistent HTTP Request in a BSP.  This means the server keeps the request open as long as possible and sends data periodically to the browser without closing the request.  In other development