Session State Replication of Referenced Objects

Here is question on Clustering and Session state replication:
          Scenario:
          Consider two Session Objects A and B.
          Object A has-a reference to object B.
          So whatever changes done to Object B is reflected in Object A.
          In-memory Session replication happens on every HttpSession.setAttribute() call.
          The question is will the two session objects(A and B) be replicated to the other cluster and will still maintain the reference relationship or will they be two separate objects with same data (in different memory locations).
          regards,
          Jaiganesh

Ok, I have been meaning to dig into session replication in a bit more detail and your question is a good excuse to do it!
          First stop the docs:
          Bea Docs
          The bits that jump out are under:
          Programming Considerations for Clustered Servlets and JSPs
          1) Session Data Must Be Serializable, so both your objects are serializable.
          2) Use setAttribute to Change Session State In an HTTP servlet that implements javax.servlet.http.HttpSession, use HttpSession.setAttribute (which replaces the deprecated putValue) to change attributes in a session object. If you set attributes in a session object with setAttribute, the object and its attributes are replicated in a cluster using in-memory replication. If you use other set methods to change objects within a session, WebLogic Server does not replicate those changes. Every time a change is made to an object that is in the session, setAttribute() should be called to update that object across the cluster.
          Likewise, use removeAttribute (which, in turn, replaces the deprecated removeValue) to remove an attribute from a session object.
          >Will the reference as shown in the step 3 will be >maintained after replication on the other cluster ?? I >guess not!!
          I don't understand "on the other cluster" There is normally one cluster made up of a few servers. The session state is maintained on one primary server and a secondary server. So you have aObj.a2 = bObj, from the docs I would understand that at the momment you called session.setAttribute the aObj and all its fields provided they are seriliazable will be replicated in Mememory.
          >There the aObj and bObj stored in the two different >session objects will not have a reference relationship >in other words if i change bObj on the other cluster >will the reference a2 of aObj be able see it ??
          This is testing the limits of my understanding, but would have thought if the objects are in different sessions they should not be able to reference each other in the manner I think you are suggesting, so if I access aObj.a2 (an instance of bObj) and changed it in one session it should not affet any other bObj unless bObj is a singleton....I think!
          What say you?

Similar Messages

  • Clustered session state replication

              We are new to WebLogic, vrs 8.1 server, and are trying to get session states to
              replicate within a cluster. We believe everything is set up per the Bea docs but
              in the end "the state" on the secondary does not seem to exist, or we do not know
              how to see it.
              Our environment:
              A domain with one admin server and four managed servers on a Sun server. Three
              of the managed servers are in a cluster, the fourth is the proxy server dispatching
              to the cluster using WebLogic HttpCluteredServlet. The app deployed to the cluster
              has the weblogic.xml session parameter for PersistentStoreType set to replciated.
              Everything runs fine till the end: A call to the app is received at the ProxyServer
              and is routed to a server in the cluster. The servlet creates a session object
              for the user. When the user executes the servlet a second time the session object
              is updated and a count is displayed to the user for each subsequent hit to the
              servlet. The session object (a java object) is serialized. Then we kill the primary
              server that is used to comunicate with the user requests. The proxyServer then
              directs the user to a different server within the cluster as it should, but the
              session object from the primary server (now killed) does not appear to be on the
              new server since a new session object gets created.
              Any ideas?
              

    Warren Anderson wrote:
              > We are new to WebLogic, vrs 8.1 server, and are trying to get session states to
              > replicate within a cluster. We believe everything is set up per the Bea docs but
              > in the end "the state" on the secondary does not seem to exist, or we do not know
              > how to see it.
              >
              > Our environment:
              >
              > A domain with one admin server and four managed servers on a Sun server. Three
              > of the managed servers are in a cluster, the fourth is the proxy server dispatching
              > to the cluster using WebLogic HttpCluteredServlet. The app deployed to the cluster
              > has the weblogic.xml session parameter for PersistentStoreType set to replciated.
              >
              > Everything runs fine till the end: A call to the app is received at the ProxyServer
              > and is routed to a server in the cluster. The servlet creates a session object
              > for the user. When the user executes the servlet a second time the session object
              > is updated and a count is displayed to the user for each subsequent hit to the
              > servlet. The session object (a java object) is serialized. Then we kill the primary
              > server that is used to comunicate with the user requests. The proxyServer then
              > directs the user to a different server within the cluster as it should, but the
              > session object from the primary server (now killed) does not appear to be on the
              > new server since a new session object gets created.
              >
              > Any ideas?
              Did you make sure everything in the session is serializable or remote?
              -- Prasad
              

  • Session state replication

    Hi.
    Has anyone got the session replication in OC4J to work
    on Windows 2000?
    We're running a 9.0.2 infrastructure and two clustered
    9.0.3 9iAS application servers, that are supposed to
    replicate HTTPServletSession state.
    We are using the default_island on a separate OC4J
    instance that are configured via Enterprice Manager to
    use multicast IP 230.0.0.1 and port 9127 (default).
    The tag <cluster-config/> is present in the file
    orion-web.xml and the <distributable/> tag is present in
    the web.xml in the WAR-file.
    No EJBs are used - only JSPs and servlets.
    Any suggestions?
    Thanks!
    Jesper

    Hi,
    This is the expected behavior. Please take a look at this document: WebLogic Server - Session Replication/Failover Scenario When Only One Server In Cluster is RUNNING (Doc ID 1292033.1)
    In a WebLogic Server domain, with a Cluster of 2 Managed Servers and a web application deployed on this Cluster, you have only one managed server running and then you make a request through a proxy server to access the application.
    The default cookie which is JSESSIONID will be created something like
    <SessionID>!<PrimaryJVMID>!NONE
    Here, you see the secondary server as NONE as there is only one server in cluster running.
    Now, you leave HTTP session idle, meaning there will be no activity and requests in it.
    Now, you bring up the second managed server instance in the cluster. The JSESSIONID for the earlier created HTTPSession will be unchanged: still
    <SessionID>!<PrimaryJVMID>!NONE
    unless there are any requests made or activity in it.
    At this point of time, if there is a failure of the Managed server, the idle in-flight HTTP Sessions which were created earlier when this managed server was RUNNING, will be dropped and there will be no failover. Only active HTTP Sessions which have a secondary JVM ID will be failed over to the secondary managed server.
    At any point, if subsequent requests are made and if any activity is made to the Idle HTTP sessions which were earlier created, the JSESSIONID gets updated with the secondary JVMID and sessions gets replicated and failed over in case of server crash.

  • Session state replication taking time to replicate in weblogic cluster

    I have a application fully serialized code with WEB-INF/lib containing the below configs with Unicast communication.
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN" "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
    <weblogic-web-app>
      <session-descriptor>
        <session-param>
          <param-name>TimeoutSecs</param-name>
          <param-value>1800</param-value>
        </session-param>
                    <cookie-http-only>false</cookie-http-only>
      <persistent-store-type>replicated_if_clustered</persistent-store-type>
                    </session-descriptor>
    </weblogic-web-app>
    OHS plugin is having below config
    LoadModule weblogic_module   "${ORACLE_HOME}/ohs/modules/mod_wl_ohs.so"
    <IfModule mod_weblogic.c>
    WebLogicCluster 172.12.113.141:7006,172.12.113.140:7006
            MatchExpression /finapp/*
    </IfModule>
    And weblogic cluster is replicating session instantly when ever there is some activities happening in the application.
    It is having a problem only in below scenario when the session is open but the user is not doing anything.
    I have 2 nodes in the cluster if one goes down(currently request serving one) it is failing over to the next but the session is not getting copied instantly. Below is the scenario where it works fine and where the replication is delayed.
    1. Both servers(server1,server2) up for some time and user logs in and is continuing work.
    2. primary server(server1) crashes in middle, secondary(server2) will take over the existing session and you will see user will be continuing the work without any issues(no logouts).
    3. After sometime server1 comes up online, user keeps on testing(clicking some tab which makes a request to server), you will see the server1 will have a replica of server2 instantly.
    4. You can bring down the server2 now and you will see the users session will not interrupt and user will be able to continue session with the server1.
    Now coming to the scenario where you will be able to delayed replication :
    1. Both servers up and user logged in and started work.
    2. Primary server(server1) goes down and secondary server(server2) will take over the session and let the user continue its work without any logout.
    2. server1 comes back online and user is not doing anything(no clicks) with application just kept the session open and server2(primary session) goes down within the replication time then the user will get logged out and might see some erratic behavior in any applications deployed to that weblogic. (We saw that if we dont shutdown server2 immediately(within 1min) and wait for 5mins+ weblogic is copying  the session from server2 to server1. After that copy if we shutdown the primary server(server2) user is not having any issues)
    To summerize if a session is active(logged in) and some activity(clicking) is going on then replication is happening instantly from primary to secondary but if the user is active(logged in) and not doing anything(not clicking) then the session from primary to secondary is taking 5minutes+
    Please let me know if there is some weblogic configs to check to reduce this time lag and let weblogic copy the session continuously either the user is performing any activity or not in the logged in session.
    Thanks,

    Hi,
    This is the expected behavior. Please take a look at this document: WebLogic Server - Session Replication/Failover Scenario When Only One Server In Cluster is RUNNING (Doc ID 1292033.1)
    In a WebLogic Server domain, with a Cluster of 2 Managed Servers and a web application deployed on this Cluster, you have only one managed server running and then you make a request through a proxy server to access the application.
    The default cookie which is JSESSIONID will be created something like
    <SessionID>!<PrimaryJVMID>!NONE
    Here, you see the secondary server as NONE as there is only one server in cluster running.
    Now, you leave HTTP session idle, meaning there will be no activity and requests in it.
    Now, you bring up the second managed server instance in the cluster. The JSESSIONID for the earlier created HTTPSession will be unchanged: still
    <SessionID>!<PrimaryJVMID>!NONE
    unless there are any requests made or activity in it.
    At this point of time, if there is a failure of the Managed server, the idle in-flight HTTP Sessions which were created earlier when this managed server was RUNNING, will be dropped and there will be no failover. Only active HTTP Sessions which have a secondary JVM ID will be failed over to the secondary managed server.
    At any point, if subsequent requests are made and if any activity is made to the Idle HTTP sessions which were earlier created, the JSESSIONID gets updated with the secondary JVMID and sessions gets replicated and failed over in case of server crash.

  • ClassNotFoundException trying to replication session state...

              Help! This has been bugging me for almost a week now and noone's been able to shed
              any light on it. My evaluation of the product is about to end and, as things currently
              stand, I've concluded that "it doesn't work"! Surely that's not right?!
              I'm getting a ClassNotFoundException when I try to store one of my classes in
              the session.
              If I have session state replication disabled then I don't get it. As soon as I
              enable replication it gets thrown. Clearly 6.1b is unable to replicate my object
              to the secondary server. Session persistence and failover is working fine with
              Strings, ArrayLists etc. It doesn't want to know about my Serializable class,
              though!
              The class is definitely on both servers since I've deployed the web application
              from the admin server and can successfully run the application on both servers
              in the cluster. It's just the persistence mechanism that is unable to find the
              class!
              Anyone got any ideas as to what I'm doing wrong?
              I'm not too keen on having to replace 6.1b with 6.0sp2 since 6.1b was recommended
              by BEA support for our evaluation and it would undo a week's work.
              Thanks,
              K.
              

    Which machine gets the error, the primary where you are doing the
              session.putValue() or does it appear on the replicated server?
              I assume your class is Serializable..
              Is the class in question in the Java classpath, or just in the web app? Try
              placing the class in the java classpath during boot on both sides, see if
              that helps.
              A full error stack would be helpful..
              -Greg
              "KPSeal" <[email protected]> wrote in message
              news:[email protected]...
              >
              > Help! This has been bugging me for almost a week now and noone's been able
              to shed
              > any light on it. My evaluation of the product is about to end and, as
              things currently
              > stand, I've concluded that "it doesn't work"! Surely that's not right?!
              >
              > I'm getting a ClassNotFoundException when I try to store one of my classes
              in
              > the session.
              > If I have session state replication disabled then I don't get it. As soon
              as I
              > enable replication it gets thrown. Clearly 6.1b is unable to replicate my
              object
              > to the secondary server. Session persistence and failover is working fine
              with
              > Strings, ArrayLists etc. It doesn't want to know about my Serializable
              class,
              > though!
              > The class is definitely on both servers since I've deployed the web
              application
              > from the admin server and can successfully run the application on both
              servers
              > in the cluster. It's just the persistence mechanism that is unable to find
              the
              > class!
              >
              > Anyone got any ideas as to what I'm doing wrong?
              >
              > I'm not too keen on having to replace 6.1b with 6.0sp2 since 6.1b was
              recommended
              > by BEA support for our evaluation and it would undo a week's work.
              >
              > Thanks,
              > K.
              

  • Query referencing session state not consistently returning data

    Hi,
    I have a form that summarizes expense data by category for employees, per fiscal year, fiscal period, and project.
    Clicking on a button next to a particular category takes the user to a new page that should display the detail of those expenses, based on expense_code.
    The expense_code is passed via URL to the second page, and the query region for the detail has the following source:
    select exp_code, JRNL_ID_NO, DESCRIPTION, REFERENCE, CUR_PER_TRAN, CUM_YTD
    from fgspec_ac where exp_code between :P118_EXPENSE_CODE_FROM and :P118_EXPENSE_CODE_TO and project=:P114_PROJECT and fis_year=:P114_FIS_YEAR and fis_period=:P114_FIS_PERIOD
    :P118_EXPENSE_CODE_FROM and :P118_EXPENSE_CODE_TO are passed via URL, and the :P114_% fields reference data on the initial form.
    The problem is that when I click on the button to bring up the detail for the first time, the query returns no rows. If I return to the original form and click on the button a second time, the query the displays the required data. This behavior is consistent, regardless of expense category, fiscal period, etc. The first time I try to access detail, no records returned, but the second time, it works.
    I have used the 'SESSION' link to debug and view the session state in each case, and the results are IDENTICAL whether the query returns data or not. That is, all 5 variables contain the exact same data.
    Do you know what I might be doing wrong?
    Thanks,
    Michelle

    Hi guys,
    Thanks very much for your replies. In fact, I have tried both methods. Yes, I am navigating from page 114 to 118, and passing values to page 118 from page 114 (ie: P114_PROJECT passes to P118_PROJECT, etc...). In my query, I have tried referencing both, with the same results.
    When checking values in session state (by using the 'SESSION' link), values from page 114 are available in both cases (when the query returns rows and when it does not). It is very strange behavior.
    I have been developing with HTMLDB for over a year now, and never seen anything like it!!! I will try loading this on HTMLDB.oracle.com, and see if it replicates, and if so, maybe you can have a look...............
    Thanks!
    Michelle

  • Different ways to referencing Session State variables

    Hi,
    According to APEX documentation there's 4 different ways to reference session state variables: http://download-west.oracle.com/docs/cd/B32472_01/doc/appdev.300/b32471/concept.htm#BEICHBBG
    In an inline PL/SQL statement, what's the difference when using the different methods? I remember reading something that the bind and static text have a size restrictions. What's the difference between the V() and NV() functions?
    Thank you.
    Martin

    Martin,
    In PL/SQL, the preferable method is to use bind variable notation, e.g., :P1_ITEM. In HTML contexts, you must use &ITEM. notation. In stored procedures, you can use v or nv, the latter function being identical to the former with the additional characteristic that it raises an exception if the retrieved value is non-numeric.
    Scott

  • Referencing session state across DBLinks

    I have a central security package that all applications access to provide item-level authorisation.
    Recent extensions to the security model require additional information from the application, held in Application Items.
    For various legacy reasons I want to avoid having to add additional parameters to the security functions called so I reference the application items via the V() function. This works perfectly on local applications (within the same database) but V() returns null values if the application is accessing the security function via a DB link.
    So, is there any way to access session state from a PL/SQL package of an application that is not running on the same database?
    Regards
    Richard

    Richard
    Something along these lines might work. Say the remote package is named 'sec var'. At the remote db create 'sec_vas' as follows. create or replace package sec_vars is
    var1 varchar2(100);   // new items needed by auth fn
    var2 varchar2(100); 
    procedure setval (var1 in varchar2,var2 in varchar2);  //sets var1/var2  with values from session state   
    function getval (var in varchar2)  return varchar2;   // the local 'v' fn
    function doAuth() return boolean;
    end;
    create or replace package body sec_vars is
    procedure setval (var1 in varchar2,var2 in varchar2) is
    begin
    sec_vars.var1:='Variable 1';
    sec_vars.var2 := 'variable 2';
    end;
    function getval (var in varchar2)  return varchar2 is
    begin
    if upper(var)='VAR1' then
       return sec_vars.var1;
    elsif  upper(var)='VAR2' then
        return sec_vars.var2;
    else
        return null;
    end if;
    end;
    function doAuth() return boolean is
    begin
    select count(*) from emp where ename=sec_vars.get_val('VAR1'');
    return true;
    end;
    end;And in the Apex db we do something like create synonym sec_vars for sec_vars@remote_db;
    // an auth process
    begin
    sec_vars.setval ('Variable 1','variable 2'); // set required session item values
    sec_vars.do_auth();
    end;varad

  • Saving session state in database table rather in websever for Ordering App

    Hi all,
    Ours is a ordering application (telecomm) domain.
    Currently, we are storing user sessions data (Order shopping cart session data) in middle tier (iPlanet web server) which inturn consumes lot of memory resources.
    Shopping cart could be in MBs if order is a huge business order.
    So in order to not to overtax web server (middle tier), we are thinking of storing session data directly in a database table to relieve the overhead on web server and make use of database for storage.
    I read that APEX (html db) is already using this "single metadata table" approach for session data management. But we are not using HTML DB to really look into.
    Can some one advise how to go about storing "user session data" directly in a "database table" for both storage and retrieval purposes instead of storing it in "webserver".
    How does this "metadata table" structure looks like. Is it more generic ?
    Really appreciate your time and help/suggestions.

    Joel,
    Thanks for your response. sorry, i meant to say that "the current application does not use APEX but will look into it".
    To build this is an utterly non-trivial exercise. Oh - it may not be so hard to save session state to a table when you POST a page. But you may want to reference this in many places, and it's a question of can you change all of these references to indirect references from session state in your application.In order to free up the load on webserver, we want to maintain session management in database. Could you please explain the above little more :
    How do we maintain the "user session" with "database table" ?
    Do we need to store "session data" at java object level or by page in database table ? How does the structure of this "metadata table" looks like.
    Thanks for your time.

  • Use session state values to set column value during insert/update

    I am building an APEX 4.2 application that uses the canned Data Loading control to upload csv data to a table.  I have modified the 'Select Data Source' page of the workflow and it now contains three LOV's that the user selects values from.  The selected values are stored in Session State.  As I'm new to APEX, I do not know how to reference Session State objects in the context of the Data Loading workflow so that the appropriate columns are set with the correct values.  My assumption is that the columns that are apart of the insert statement reside in a collection somewhere.  I just don't know how to loop through the collection, determine the correct column, and then set that column's value equal to the corresponding LOV value in Session State.

    Scott,
    This is in version 2.2.1 and there are no caching features available.
    The application does require login.
    I'm playing around with the APP_UNIQUE_PAGE_ID right now but I am finding that even in the builder if I edit the attributes of a report column and then try to edit another column it will bring up the last column I edited. Even if I use the record navigation buttons next to the Apply Changes button it will keep bringing me the same page over and over unless I constantly refresh the pages.
    Greg

  • Update Session State for only one item

    I have several hidden items (e.g. fund, object and unit) that hold values that are input parameters for a function that returns a SQL statement to a 'PL/SQL Function Body Returning SQL Query' region. These hidden items are set when a user selects a value from a pop-up tree. I want to dynamically set corresponding visible prompt text items (fund_prompt, object_prompt and unit_prompt) to a descriptive value that makes sense to the user. I've tried using a source type of SQL and placing the following SQL statement in the source
    SELECT child_prompt
    FROM fr_hierarchy_fund
    WHERE child = :FUND;
    When the value in one of the hidden items is changed, the visible prompt item displays "undefined" until the page is submitted.
    Is there a way to set the session state of an item without submitting the page?
    Thanks
    David

    David,
    Items, hidden or not, are not set in session state until the page is submitted. You might consider submitting the page with a javascript event on your popups. The request value can be used to control what processing you do or don't do on page submission and a branch right back to the page should allow you to show everything based on current item values.
    Scott

  • Controlling Session State and Submit Processing

    I am trying to gain a fundamental understanding of how to control submit processing and session state, etc.
    For example, I have a popup lov that lists names and returns id for the parent record. When the user make the selection using this pop lov, I then have an id that I want to use to lookup the default value for another field.
    How do you submit a page for re-rendering (i.e, you have condition expressions referencing values that the use has set) without triggering the auto dml and page branch?
    For example, I have a form for specifying tns names with 2 buttons, 'Advanced Config' and 'Basic Config'. The idea is to hide/show items corresponding to basic or adv. config options, etc.
    My first approach was to have the buttons do a redirect to the same page, setting P5_USE_ADV_CONFIG_YN to Y or N without clearing the cache. When the page refreshes, the conditional rending has occured as desired (i.e., I set the condition on my form items to reference P5_USE_ADV_CONFIG = Y or N, etc.), but user's data values have been lost since the record was reloaded from the database.
    So..I tried putting a condition on the fetch procedure to prevent the record from being re-read. However, this left all the fields empty which indicates that the item's session state has been completed cleared! Huh? I didn't want ask for or want this behavior. Hmmm.
    So, I start thinking that the persisted session wasn't updated since I didn't do a submit and so when the page was requested, it behaved as it should, but not what I had in mind. THUS...I believe I need to submit the page and prevent the auto-dml and page branching afterwards....but how? I feel that I am missing something very fundamental here and that the answer may also help me with other related questions:
    * How does the confirm delete examples work? How is the processing stopped when the user presses cancel?
    * How can you do validations and stop dml processing without losing the user values?
    * How can you display and error page and then return to where the user was with the values still present?
    * How can I do a secondary sql value lookup based on the users selection in a popup lov? (User selects a Database/DbID - then I want to lookup host using DbId)
    I haven't been successful understanding this from the manuals, but someone can point me to some material that explains submit processing, redirects, etc. I would be happy to do some more digging.
    Thanks greatly in advance.

    Thanks Scott,
    I may be being dumb here but I don't see how that would help...
    P250_PROJECT and G_PROJECT are currently kept in sync by app logic. Whichever is used to drive, if the page is rendered from cache then the app logic is not executed, so the rendered page contents are not those keyed by P250_PROJECT, as illustrated in steps 1-4 of the problem above.
    The user sees X, the session items say Y. The engine doesn't know what the user is seeing.
    when page P is POSTed, its hidden item P250_PROJECT should always be used to derive the application item G_PROJECT. Then whether the page was pulled from cache or rendered anew via a click from the sidebar link, the project ID is determined by the contents of that page.
    As I said above I tried this, with the 'Edit' branch set to:
    Set these items: G_PROJECT
    With these values: &P250_PROJECT.
    but it makes no difference. The project ID is not determined by the rendered page contents - the engine gets the value of P250_PROJECT from session state.
    I can code the 'Edit' pages such that they check permissions and if necessary redirect back to p250 (conditional before-header branch), but that's a clunky cure rather than the prevention I was hoping for.
    Please tell me if my understanding is incorrect.
    jd

  • ??? On Session State

    Background info:
    I have a field that could have two different types of input, one would be numeric (such as a PK) the other input to it would be text. To ensure the Automated Row Fetch always pulls the PK properly I am using a computation ON LOAD to turn the text into numeric so that when the Automatic Page Load runs it will always pull from the database based on the PK.
    This part is working properly the problem is that I have an item that is a select list and it unforunately has an dynamic LOV with a query of select a,b from table_xyz where value = :session_state_of_pk
    This is causing me a problem because it is referencing the "text value" and not the numeric value. Even though when I change my page view to "Events" the page rendering shows computations before Items. I even did a Pl/sql process ON LOAD to insert the :session_state value to a debug table.
    So my question is ... If the pl/sql on load process is holding the correct value then why is the LOV of a page item not using the correct value??
    This is the error I get on the page Item that is an LOV:Error: ORA-01722: invalid number performing List of Values query

    Vikas, I have done this and here are the results:
    .01: S H O W: application="110" page="103" workspace="" request="" session="6865688852817169"
    0.01: Language derived from: FLOW_PRIMARY_LANGUAGE, current browser language: en-us
    0.01: alter session set nls_language="AMERICAN"
    0.01: alter session set nls_territory="AMERICA"
    0.01: NLS: CSV charset=WE8MSWIN1252
    0.02: ...NLS: Set Decimal separator="."
    0.02: ...NLS: Set NLS Group separator=","
    0.02: ...NLS: Set date format="DD-MON-RR"
    0.02: ...Setting session time_zone to dbtimezone
    0.02: NLS: Language=en-us
    0.02: Application 110, Authentication: CUSTOM2, Page Template: 724212235889446
    0.02: ...Supplied session ID can be used
    0.02: ...Application session: 6865688852817169, user=JRP22
    0.02: ...Determine if user "JRP22" workspace "1786101047996118" can develop application "110" in workspace "1786101047996118"
    0.03: Session: Fetch session header information
    <b>0.03: Saving g_arg_names=P103_IP_ID and g_arg_values=077.243
    0.03: ...Session State: Save Item "P103_IP_ID" newValue="077.243" </b<"escape_on_input="N"
    0.03: ...Metadata: Fetch page attributes for application 110, page 103
    0.03: Fetch session state from database
    0.04: Branch point: BEFORE_HEADER
    0.04: Fetch application meta data
    0.04: Authorization Check: "6961000503551770" User: "JRP22" Component: "PAGE"
    0.06: Computation point: BEFORE_HEADER
    <b>0.06: ...Perform computation of item: P103_IP_ID, type=QUERY
    0.06: ...P103_IP_ID=select ip_id from IP where IP = :P103_IP_ID;
    0.06: ...Session State: Saved Item "P103_IP_ID" New Value="32"
    0.06: Processing point: BEFORE_HEADER
    0.06: ...Process "TEST DB INSERT SESSION STATE P103_IP_ID": PLSQL (BEFORE_HEADER) insert into t (col1,col2,tstamp) values ('p395',:p103_ip_id,systimestamp);</b>
    0.08: Show page template header
    0.09: Computation point: AFTER_HEADER
    0.09: Processing point: AFTER_HEADER
    <b>0.09: ...Process "Fetch Row for IP": DML_FETCH_ROW (AFTER_HEADER) F|#OWNER#:IP:P103_IP_ID:IP_ID
    </b>0.10: ...Process "Fetch DNS_NAME To Buffer": PLSQL (AFTER_HEADER) :P103_DNS_NAME_BUFFER := :P103_DNS_NAME;
    0.11: ...Session State: Save Item "P103_DNS_NAME_BUFFER" newValue="3657" "escape_on_input="N"
    0.11: ...Process "Get Next or Previous Primary Key Value": GET_NEXT_OR_PREV_PK (AFTER_HEADER) #OWNER#:IP:IP_ID::IP::P103_IP_ID:P103_IP_ID_NEXT:P103_IP_ID_PREV::::P103_IP_ID_COUNT:
    0.13: ...Session State: Save Item "P103_IP_ID_NEXT" newValue="33" "escape_on_input="N"
    0.13: ...Session State: Save Item "P103_IP_ID_PREV" newValue="31" "escape_on_input="N"
    0.14: ...Session State: Save Item "P103_IP_ID_COUNT" newValue="32 of 3434" "escape_on_input="N"
    0.14: ...Process "Fetch MAC_ADDRESS": PLSQL (AFTER_HEADER) select mac_address into :P103_MAC_ADDRESS from mac_address where IP_ID = :P103_IP_ID;
    0.15: ...Session State: Save Item "P103_MAC_ADDRESS" newValue="00-16-3G-33-25-33" "escape_on_input="Y"
    0.15: ...Process "Fetch Container_Type": PLSQL (AFTER_HEADER) select container_type into :P103_CONTAINER_TYPE from container_type where container_type_id = :P103_CONTAINER_TYPE_ID;
    0.16: ...Session State: Save Item "P103_CONTAINER_TYPE" newValue="BASE_UNIT" "escape_on_input="Y"
    0.16: ...Process "Populate Hidden Assign value": PLSQL (AFTER_HEADER) :P103_ASSIGNED_BUFFER := :P103_ASSIGNED;
    0.16: ...Session State: Save Item "P103_ASSIGNED_BUFFER" newValue="Y" "escape_on_input="N"
    0.16: Authorization Check: "4769021032313739" User: "JRP22" Component: "tab"
    From Session State after the page has loaded:
    Application Page Item Name Display Item Value Status
    110 103 P103_IP_ID Hidden 32 U
    Vikas: From the debug info you can the value comes in with the the IP ( I have removed the first two octets from the debug information) "Saving g_arg_names=P103_IP_ID and g_arg_values=077.243"
    A few steps later a computation is performed and the IP is chagned to an IP_ID which the value is 32, this is correct at this point.. Following that there is a pl/sql insert of :P103_IP_ID and that value is 32 inside the db table.
    Here is what it looks like on the screen:
    <b>Any ideas why the Select List LOV does not like this value?</b>
    Here is the actual LOV query:
    select dns_name,dns_name_id from dns_name where ip_id = :p103_ip_id
    Message was edited by:
    Justin P

  • Session state, again

    Hi,
    I am still struggling after session state updates.
    Here is my problem:
    I have a page containing two regions (besides the breadcrumbs):
    the first region contains a couple of combo boxes containing "filters" for the chart.
    The second region contains a pie chart and the sql expression contains two bind variables referencing the aforementioned filters.
    The chart in turn contains links to itself, because the value represented by each slice can be used to split the data into further categories. This is achieved via a hierarchical query representing categories of items, so, for instance, category "Food" is parent of "Beverage" and "Beverage" is parent of "Wines". So when you click on slice "Food", the underlying query returns all the categories belonging to "Food".
    Until now I could not figure out a way to handle the browser's back button correctly, because the "recursive" nature of this scenario is messed up by session state, whose values persist beyond the scope of each page.
    This situation leads to strange results, where the form fields show the correct data, whilst the chart is drawn on entirely different values. This happens only when navigating backwards or forwards using the browser's back or forward button.
    Is there any way to force form values to take precedence over session state values, eventually via javascript, so that the back button returns a meaningful page?
    I tried with different approaches but with little success, so I was wondering if you have any known workaround.
    Thanks,
    Flavio

    Hi Francis,
    We have used the following code in our page template and it works.
    &lt;script&gt;
    //Disables the browser back button
    javascript:window.history.forward(1);
    &lt;/script&gt;
    And in the "Error Page Template Control" to
    &lt;TABLE &gt;
    &lt;TR&gt;
    &lt;TD valign="TOP"&gt;&lt;IMG SRC="&IMAGE_PREFIX.error.gif" width=32 height=32&gt;&lt;/TD&gt;
    &lt;TD valign="CENTER"&gt;&lt;font size=+1&gt;#MESSAGE#&lt;/font&gt;&lt;/TD&gt;
    &lt;/TR&gt;
    &lt;TR&gt;&lt;TD&gt;&lt;A HREF="f?p=&FLOW_ID.:&FLOW_STEP_ID.:&SESSION.::&DEBUG."&gt;&lt;IMG SRC="&IMAGE_PREFIX.back.gif" title="Back" alt="Back to previous page" width=32 height=32 border=0&gt;&lt;/A&gt;&lt;/TD&gt;
    &lt;TD&gt;Back&lt;/TD&gt;
    &lt;/TR&gt;
    &lt;/TABLE&gt;
    &lt;table&gt;
    &lt;tr&gt;&lt;TD&gt;&lt;A HREF="f?p=100:1:&SESSION.::&DEBUG." Title="Click here to go back to Main Menu"&gt;Go back Home&lt;/A&gt;&lt;/TD&gt;&lt;/tr&gt;
    &lt;/table&gt;
    You need to change or add error template because the default functionality of "javascript:window.history.go(-1)" will not work
    Hope this helps
    Vivek

  • Problem In Session State

    Hai, I'm Using VS2010 and SQL Server 2005.
    I have a problem in Session state;
    //View.aspx.cs
    // In this page just I store a textbox into a session variable.
    protected void btnEdit_Click(object sender, EventArgs e)
            Session["rollno"] = txtRollNo.Text;
                Response.Redirect("Edit.aspx");
    //Edit.aspx.cs
    //In this page I retrieve the session value which is stored in previous page
           protected void Page_Load(object sender, EventArgs e)
            txtRollNo.Enabled = false;
            if (!IsPostBack)
                txtRollNo.Text = Session["rollno"].ToString();
                getdata();
     public void getdata()
            SqlConnection con = new SqlConnection("Data Source=SERVICETEAM-PC;Initial Catalog=csc;User ID=sa;Password=kavi");
            con.Open();
            SqlCommand cmd = new SqlCommand("Select * from Csc where Roll_No='" + txtRollNo.Text + "'", con);
            SqlDataReader dr = cmd.ExecuteReader();
            if (dr.Read())
                txtName.Text = dr.GetString(1).ToString();
                txtAddress.Text = dr.GetString(2).ToString();
                txtMobileNo.Text = dr.GetString(3).ToString();
                txtYesNo.Text = dr.GetString(4).ToString();
    From the above code, I got an error when I press Edit button in View.aspx page.
    The Error is
    Description: An unhandled
    exception occurred during the execution of the current web
    request. Please review the stack trace for more information about the error and where it originated in the code. 
    Exception Details: System.Web.HttpException: A page can have only one server-side Form
    tag.
    Source Error: 
    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack
    trace below.
    Help Me.....

    Hai,
    I'm using VS2010 and SQL Server 2005.
    I have a problem in Session state.
    See below is my code,
    //View.aspx.cs
    //Here I assign a textbox value to session
    protected void btnEdit_Click(object sender, EventArgs e)
            Session["rollno"] = txtRollNo.Text;
                Response.Redirect("Edit.aspx");
    //Edit.aspx.cs
    //Here I assign a session value to textbox, which is stored in last page.
    protected void Page_Load(object sender, EventArgs e)
            txtRollNo.Enabled = false;
            txtRollNo.Text = Session["rollno"].ToString();
            getdata();
    public void getdata()
            SqlConnection con = new SqlConnection("Data Source=SERVICETEAM-PC;Initial Catalog=csc;User ID=sa;Password=kavi");
            con.Open();
            SqlCommand cmd = new SqlCommand("Select * from Csc where Roll_No='" + txtRollNo.Text + "'", con);
            SqlDataReader dr = cmd.ExecuteReader();
            if (dr.Read())
                txtName.Text = dr.GetString(1).ToString();
                txtAddress.Text = dr.GetString(2).ToString();
                txtMobileNo.Text = dr.GetString(3).ToString();
                txtYesNo.Text = dr.GetString(4).ToString();
    From the above code If I the Edit button, It will show an error like 
           

Maybe you are looking for

  • VAT calculation through Pricing Procedure of MM

    Hello gurus, I have a doubt can we calculate and post the vat thru purchase condition type in pricing procedure, for excise and cess we are using Tax code with tax procedure TAXINJ, we are trying hard for it., we have even created new transactiion ke

  • How to avoid duplicate data loading from SAP-r/3 to BI

    Hi !        I have created one process chain that will load data into some ODS from R/3,where(in R/3)the datasources/tables r updated daily.        I want to scheduled the system such that ,if on any day the source data is not updated (if the tables

  • Acrobat 9 Pro can't open zip attachment in Adobe tutorial PDF

    I'd like to go through one of the CSS tutorials here on the Adobe site, and have downloaded the relevant PDF which includes a .zip attachment for the source files needed to follow the tut. Problem is, Acrobat 9 Pro keeps telling me "Acrobat cannot op

  • International characters input

    Hi all, I am facinf a small problem here. I am using JSP and servlet to input some data to a webpage. But the problem is that if I chose any other character set other then UTF-8 on the web page encoding all the special characetrs simply disappear. By

  • MacPro 2008 up to 10.9.3 - USB performance drop

    I have a vanilla early 2008 8-core Mac Pro with 8GB of RAM and about 500 GB of HD. I use it exclusively for software defined radio, which is an application that in my instance, transfers a lot of data to the computer via USB from a device called an S