Maintaining OAS cartridge state

I'm not sure this forum is the right place to post this question
but anyway. My problem is to create OAS cartridge application
(JWeb or PLSQL ) that uses Oracle stored PLSQL packages. Each
time the OAS submits request to the stored procedure it seems
PLSQL package has lost its state. That means that all packaged
variables has been initialised. For example, consider this PLSQL
code stored in Oracle database
Package Test IS
Procedure First;
FUNCTION Second RETURN INTEGER;
END;
Package body Test IS
myVar INTEGER;
Procedure First IS
BEGIN
myVar := 1;
END;
Function Second RETURN INTEGER IS
BEGIN
RETURN myVar;
END;
END;
Let's say that created HTML wiht a button that fires Test.First
using either JWeb or PLSQL cartridge. After then it generates
HTML pages with another button. Clicking on that button fires
Test.Second functions using the same cartridge. That function is
supposed to return 1. But each time it returned NULL instead.
The documentation for OAS gives very confusing information about
that. It states that it is possible bind clients to particular
cartridge instance by enabling client sessions. Doing that
doesn't solve above mentioned problem. Using cookies will not
help as well because I cannot store structures like records,
PLSQL tables or cursors this way.
Andrei Filimonov
null

Andrei,
Here is a response from someone in the OAS team. Hope this
helps...
What you need is access to the same database session for all
the requests
from the same client. The session feature of OAS does guarantee
you access to the
same cartridge instance, but it's upto the cartridge instance
whether to maintain
the database session as part of the instance state or not.
You can certainly achieve this by JWeb cartridge by storing the
database session
handle as part of the instance state. As far as PL/SQl cartridge
is concerned, this
is not possible until OAS 4.0.8 which has this new feature.
Regards,
Andrei Filimonov (guest) wrote:
: I'm not sure this forum is the right place to post this
question
: but anyway. My problem is to create OAS cartridge application
: (JWeb or PLSQL ) that uses Oracle stored PLSQL packages. Each
: time the OAS submits request to the stored procedure it seems
: PLSQL package has lost its state. That means that all packaged
: variables has been initialised. For example, consider this
PLSQL
: code stored in Oracle database
: Package Test IS
: Procedure First;
: FUNCTION Second RETURN INTEGER;
: END;
: Package body Test IS
: myVar INTEGER;
: Procedure First IS
: BEGIN
: myVar := 1;
: END;
: Function Second RETURN INTEGER IS
: BEGIN
: RETURN myVar;
: END;
: END;
: Let's say that created HTML wiht a button that fires
Test.First
: using either JWeb or PLSQL cartridge. After then it generates
: HTML pages with another button. Clicking on that button fires
: Test.Second functions using the same cartridge. That function
is
: supposed to return 1. But each time it returned NULL instead.
: The documentation for OAS gives very confusing information
about
: that. It states that it is possible bind clients to particular
: cartridge instance by enabling client sessions. Doing that
: doesn't solve above mentioned problem. Using cookies will not
: help as well because I cannot store structures like records,
: PLSQL tables or cursors this way.
: Andrei Filimonov
null

Similar Messages

  • Maintaining persistent client state in Oracle 8.1.6

    I'm running Oracle 8.1.6 on Windows NT 4.0.
    What are the methods to maintain the state of HTTP session (variable values, maybe transaction state) between the requests of the same user, in other words, how can I maintain HTTP session state in Oracle 8.1.6?
    It's preferable to avoid using cookie, but I'll be very grateful for any advice.
    Thanks in advance, Alex.

    Here's my Javascript Code for writing the Cookie (adapted from www.webmonkey.com):
    Htp.p('<script language="JavaScript"><!--
    function SetCookie(){
    if(document.cookie=="")
    {var t_ck="cotavalor=p_cliente:'&#0124; &#0124;to_char(t_new_CV_Cookie,'9999999999')&#0124; &#0124;'";var t_date=new Date("December 31, 2050");var t_ck_date=t_date.toGMTString();
    t_ck=t_ck+";expires="+t_ck_date+";path=/";
    document.cookie=the_cookie;}
    else {return false;}}
    //--></script>
    <script language="JavaScript"><!--
    SetCookie()
    //--></script>');
    Now here's my PL/SQL code for reading it:
    t_cookie := owa_cookie.get('cotavalor');
    Simple. I had to write that Javascript cause the Functions provided by Oracle didn't seem to work at all, while the Javascript version works easily.
    null

  • When I switch back to an ongoing application, from the switcher, it reverts to its own 'homepage' rather than the stay at the state/stage I left it at. How can I force applications to maintain the current state?

    iPhone 4S with the latest updates 8.1.3 (12B466) installed.
    When I switch back to an ongoing application, from the switcher, it reverts to its own 'homepage' rather than the stay at the state/stage I left it at.
    How can I force applications to maintain the current state?
    I am in the process of getting enough screenshots to demonstrate further.

    ios7 keeps refreshing apps after switching
    solcwd

  • Maintaining previous idle state while loading a waveform

    Hi,
    Is it possible to generate waveform1, in idle state hold the last bits of waveform1 (using 'X' in the idle state function), then load waveform2 while still maintaining the idle state from waveform1, and then generate waveform2 having it start from the idle state of waveform1?  Or is the idle state lost when waveform2 is loaded and/or initiated?
    Thanks!

    Hi hch3,
    Our Digital boards hold last value when in generation mode. So they will hold the last state by default, and once stopped will hold last value until the board is reset. You can then load a waveform, while it holds last state, and once starting your generation session again, it will generate waveform 2 as you expect.
    Some terminology discussion: An Idle State is what happens you are waiting for a trigger, you are in a pause trigger state, or the board completes normally. It sounds like in your scenario, you are outside of a session and you are loading a new waveform to be generated by your session. In this case, the board will hold its last value (default Idle State setting).
    We give customers the ability to change the idle state behavior though the niHSDIO_ConfigureIdleState function or Configure Idle State VI. It is default hold last value, but you can set it to logic high, logic low, or tristate if you desire.
    If you do not want to hold last value any longer for any reason, the HSDIO Tristate VI is what I would recommend to set the data lines back to their initial default state. Calling a board reset will cause the data lines to tristate as well.
    Kyle A.
    National Instruments
    High Speed Digital I/O Product Support Engineer - R&D

  • How to maintain the hover state of a button while it is in it's current page?

    Hi,
    I'm just a beginner in actionscript 3. I have this code about navigation using movieclip buttons. I just made the currently selected button disabled when it is in the current page but I just cant figure out on how to maintain it in its hover state (It keeps on returning to its normal state). Any ideas, your help will be very much appreciated. Thanks.
    Here's the code I've written on the first frame on the main timeline(scene1), I have 4 buttons namely mcButton1, mcButton2, mcButton3, mcButton4 and 4 labeled frames, page1, page2, page3 and page4.:
    var page:String;
    var btnArray:Array = [mcButton1, mcButton2, mcButton3, mcButton4];
    var pageArray:Array = ["page1", "page2", "page3", "page4"];
    for (var i:int = 0; i < btnArray.length; i++) {
        btnArray[i].buttonMode = true;
        btnArray[i].addEventListener(MouseEvent.CLICK, onMouseClick);
        btnArray[i].addEventListener(MouseEvent.ROLL_OUT, onMouseOut);
        btnArray[i].addEventListener(MouseEvent.ROLL_OVER, onMouseOver);
    function onMouseClick(event:MouseEvent):void {
        for (var i:int = 0; i < btnArray.length; i++) {
            if (event.currentTarget == btnArray[i]) {
                btnArray[i].mouseEnabled = false;
                page=pageArray[i];
                play();
            else {
                btnArray[i].mouseEnabled = true;
    function onMouseOut(event:MouseEvent){
            event.currentTarget.gotoAndPlay("out");
    function onMouseOver(event:MouseEvent){
            event.currentTarget.gotoAndPlay("over");

    use:
    var lastClickedButton:MovieClip;
    var page:String;
    var btnArray:Array = [mcButton1, mcButton2, mcButton3, mcButton4];
    var pageArray:Array = ["page1", "page2", "page3", "page4"];
    for (var i:int = 0; i < btnArray.length; i++) {
        btnArray[i].buttonMode = true;
        btnArray[i].addEventListener(MouseEvent.CLICK, onMouseClick);
        btnArray[i].addEventListener(MouseEvent.ROLL_OUT, onMouseOut);
        btnArray[i].addEventListener(MouseEvent.ROLL_OVER, onMouseOver);
    function onMouseClick(event:MouseEvent):void {
        for (var i:int = 0; i < btnArray.length; i++) {
            if (event.currentTarget == btnArray[i]) {
                //btnArray[i].mouseEnabled = false;
    lastClickedButton.gotoAndPlay("out");
    lastClickedButton=MovieClip(event.currentTarget);
                page=pageArray[i];
                play();
            else {
                btnArray[i].mouseEnabled = true;
    function onMouseOut(event:MouseEvent){
    if(lastClickedButton!=event.currentTarget){
            event.currentTarget.gotoAndPlay("out");
    function onMouseOver(event:MouseEvent){
            event.currentTarget.gotoAndPlay("over");

  • Maintaining portlet P1 state when submiting portlet P2

    We have a problem regarding maintaining the state of a form...
    The scenario :
    1- You fill in a form in portlet P1 without submitting it to the server.
    2- If you work on portlet P2 and submit a form OR work on another page, the filled in form in portlet P1 is lost.
    Form state is not maintained if not submitted to server. We need to maintain the state of a form that has not been submitted.
    Any suggestions on how this can be achieved?
    NOTE : We are using Weblogic Portal 10.2
    Edited by sarguin at 06/06/2008 8:07 AM

    Hi Guys,
    One good thing i found is
    When i perform the same operations (as described in the first post of this thread) with JSR168 Portlets then it is working Perfectly.
    So i feel , only the problem is with JPDK Porltet and not with Oracle Portal Server.
    It's good to see that JSR168 are working fine except
    portletURL.setPortletMode(PortletMode.EDIT) ( till now i found this only )
    nJoy Work
    ~Neeraj Sidhaye
    ChkOut_ChkIn @ Yahoo Dot Co Dot In
    ExtremePortal @ Gmail Dot Com

  • Maintain Report Input State on Validation

    Good Morning Everyone,
    I have a report region for which I need to maintain input state during validation. I made several attempts to effect this using page and region caching, NULL'ing out the request object (if that means anything), etc. I have searched the forum and Google for answers, but chances are that I perhaps just don't know what to search. Here is a quick run-down. I have a report region with 4 inputs per row (2 drop downs, 2 text fields). The user enters data and then submits the page. When a validation fails, it gives the appropriate message, but overwrites all inputs (rather than caching the user's input and re-displaying). This forces the users to re-enter alllll thaaat daaatta rather than just fixing the couple problems that caused the validation failure. I know this is probably some simple setting or requires a couple processes; I just haven't solved the problem after 3 days of tinkering. Does anyone have any suggestions (simple or otherwise). Really, all I need is to be pointed in the right direction. Sorry for the lengthy post. Thanks.
    V/R,
    Erik
    Edited by: user593880 on Jul 12, 2011 7:08 AM

    What version of Apex? Is it a manual tabular form?
    In previous versions or in a manual tabular form if you want to keep the changes, you will need to display the validation error on an error page, or create a workaround using collections.
    Retaining tabular form values to keep user inputs
    Tabular Form Validation - Values Reset

  • Order not maintained in MERGE statement

    I am using a MERGE statement as follows:
    MERGE INTO target T
    USING ( select * from source order by data_id ) S
    on ( T.data_id = S.data_id )
    when matched then update
    set t.code = s.code
    when not matched then insert
    (t.code, t.data_id )
    values
    (S.code, S.data_id )
    But the newly inserted records in the target table are not ordered in the same order as the source table.
    E.g
    source
    data_id(pk)     code     
    1     1
    2     2
    3     2
    target
    pk_col data_id     code
    1     3     1
    2     1     2
    3     1     2
    I was expecting records in noth tables to be sorted in order of data_id
    Is this a limitation of merge statement or is there any workaround.

    bony wrote:
    I was expecting records in noth tables to be sorted in order of data_id
    Is this a limitation of merge statement or is there any workaround.No, it is not a limitation. It is 101 of relational databases - there is no row order in table rows. Same query can return rows in a different order next time you run it unless ORDER BY is specified.
    SY.

  • How do I export all my Iphoto photos to my external hard drive, maintaining their current state?

    So I did the classic click and drag method, putting all my photos into my external hard drive, fast and easy. But what I noticed was that no information about the pictures was kept, no dates, locations etc. If you drag one picture the information comes with it, but not if you take a bunch at the same time. Then the original date is replaced by today's. I've got over 20.000 photos and I really want them on my hard drive, can someone please help me out here?

    Export them using the appropriate options to include the desired metadata - see the user tip on exporting for details on eachoption
    As to date - you probably are confusing the file date with the photo date - two totally different things - the photos date is internal to the photo in the EXIF data and is view using photo viewing software like preview or iPhoto - the file date it only concerned with th efile information and is views with file viewer software like nder
    LN

  • OAS 4.0.8.1 & JWEB cartridge - ows 10911

    I am running OAS 4.0.8.1 on NT sp5. When I startup my jweb cartridge I get ows-04793 and ows-10911. I can run helloworld correctly but when I run my application I get the same errors above again. Is anyone running OAS 4.0.8.1 on NT with a jweb cartridge and not getting these errors. Even if I use the default cartridge from Oracle without altering anything I get these errors. ???

    I increased the severity level for logging to 15 for the Cartridge configuration
    in the OASManager.
    It says init method did not return. For my init method I have that following :
    public void init(ServletConfig config) throws ServletException
    super.init(config) ;
    All the above was generated by the Servlet Wizard.
    Below if the level 15 trace information :
    OWS-10911: Throwing exception for reason: wrkwExecute: Exec callback returned WRB_ERROR `
    OWS-10833: Cartridge HelloServlet/HelloCart init runtime callback did not return WRB_DONE `
    OWS-10911: Throwing exception for reason: wrkwfInit:Error in wrkwfInit `
    OWS-10911: Throwing exception for reason: wrkwfStartOrig:Error at creation time `
    OWS-10911: Throwing exception for reason: wrkwfStart: Cartridge Instance factory creation failed. `
    OWS-10803: Cartridge instance factory for HelloServlet/HelloCart not intialized `
    OWS-10911: Throwing exception for reason: No Carrtridge Instance Factories Initialized Properly `
    OWS-10821: Application HelloServlet failed to deregister with the name server `
    OWS-10850: Cartridge Server HelloServlet received exception IDL:oracle/OAS/Cartridge/InitFailed:1.0 while deregistering
    Can anyone advise why and what needs to be
    done to fix this ??
    Please help.
    Thanks,

  • OAS 4.0.8.1 - JServlet Cartridge - error OWS-04769

    Hi,
    I'm trying to run servlets under the JServlet Cartridge of OAS. My servlet uses the HttpSession class to track sessions. After receiving requests from 3 clients the servlet stops running with the following messages in wrb.log:
    08-15-2000 14:22:56 460136 darkstar `Broker` 5786 1 0x10fff `OWS-04769: Number of instances for Cartridge Secure_Apps/Login at darkstar has reached the maximum. `
    08-15-2000 14:22:56 484025 darkstar `Broker` 5786 1 0x10fff `OWS-04760: Disable Host darkstar for Cartridge Secure_Apps/Login. `
    08-15-2000 14:22:56 524139 darkstar `Broker` 5786 1 0x10fff `OWS-04759: No host is available to create Cartridge Secure_Apps/Login. `
    How do I increase the number of cartridge instances? Or how else can I work around this problem.
    Thanks.
    Martin
    null

    I increased the severity level for logging to 15 for the Cartridge configuration
    in the OASManager.
    It says init method did not return. For my init method I have that following :
    public void init(ServletConfig config) throws ServletException
    super.init(config) ;
    All the above was generated by the Servlet Wizard.
    Below if the level 15 trace information :
    OWS-10911: Throwing exception for reason: wrkwExecute: Exec callback returned WRB_ERROR `
    OWS-10833: Cartridge HelloServlet/HelloCart init runtime callback did not return WRB_DONE `
    OWS-10911: Throwing exception for reason: wrkwfInit:Error in wrkwfInit `
    OWS-10911: Throwing exception for reason: wrkwfStartOrig:Error at creation time `
    OWS-10911: Throwing exception for reason: wrkwfStart: Cartridge Instance factory creation failed. `
    OWS-10803: Cartridge instance factory for HelloServlet/HelloCart not intialized `
    OWS-10911: Throwing exception for reason: No Carrtridge Instance Factories Initialized Properly `
    OWS-10821: Application HelloServlet failed to deregister with the name server `
    OWS-10850: Cartridge Server HelloServlet received exception IDL:oracle/OAS/Cartridge/InitFailed:1.0 while deregistering
    Can anyone advise why and what needs to be
    done to fix this ??
    Please help.
    Thanks,

  • Maintain Fiancial Statement Version with alternative account

    Hello,
    We have a global chart of account, for a certain company code, each of
    the accounts from the global chart of account has its own alternative
    account from an alternative Chart of Account.
    We have defined the Financial Statement under the principal Chart of
    Account but have assigned the alternative accounts.
    When we execute the S_ALR_87012284 transaction to display the
    balance sheet, we are not able to see the node text of our Financial
    Statement structure.
    What is the procedure to correctly display Balance Sheet Structure,
    maintaining the nodes and node text?
    Thank you
    Daniel

    Hi,
    When you execute the T.code S_ALR_87012284,select special evaluations tab,select alternative account number check box:
    Pls go thru below:
    Issue Alternative Account Number
    If this parameter is set, the G/L account number is replaced by the alternative account number (from the company code-specific G/L account master record).
    Requirements
    These account numbers are only substituted if country charts of accounts are maintained in the global data of the company codes selected, and these charts of accounts differ from those belonging to the company code. The alternative account numbers in the G/L account master records must be contained in the respective country chart of accounts. The alternative account number is only shown on the financial statement if you have explicitly assigned it to the appropriate items of the financial statement version. You must therefore maintain your financial statement version so as to contain the alternative accounts.
    Thanks
    Aravind

  • Maintain State of a Tree Table

    Hi,
    I am using Tree Table with EJB Datacontrol. I am fetching child records on Disclose icon of a treetable. I have added context menu on tree table to navigate to another taskflow. I want to maintain the same state i.e. Tree Table should be in Expanded State for those nodes which were disclosed by user previously) of a tree table when use clicke on Back button of a another taskflow.

    Hi Bill,
    I think that that is the only example I've seen of anyone storing tree node selections.
    The only other thing that springs to mind would be to use a "region pull" and put the report on another page and have the click of a node trigger the Ajax call that sets a PK value (or whatever would be required for a report) and then pulls the report into a DIV on the tree's page. That way, the page isn't even reloaded. Of course, that is for a report - not sure if it would work ok for forms
    Andy

  • Layer palette not maintaining state, what to do??

    Problem: Layer palette chages state between the closing and reopening of a file.
    What I would like to be able to do is open a .ai file and have the layer palette exactly the way the way I left it when I closed the file. Currently upon reopening a file many of the layers will be fully expanded and I have to go through and collapse them all.
    Is there a way to force Illustrator to maintain layer palette state between file sessions?
    Thanks.

    The behaviour - or the issue - has been introduced in Illustrator 9, the first version which included nested layers. The behaviour has been legitimately criticised pretty often.
    However, if you want to collapse/expand all layers in one step you might consider converting your main layers into sublayers. That is:
    • Create a new 'master layer' on top of the entire stack of main layers
    • Drag all main layers onto the master layer in order to make them sub layers of the master layer
    • Now you can Alt/Option Click the triangle on the left-hand side of the master layer in order to collapse or expand all sublayers
    Of course, this way is only applicable if using sublayers is an option for you.

  • Flexlib windowshade opened state maintain

    Hi,
    I have flexlib WindowShade component in repeater in my Flex + AIR application.
    <mx:XML id="mainMenuXML">
        <items>
            <item value="abc" />
            <item value="xyz" />
            <item value="lmn" />
        </items>
    </mx:XML>
    <mx:VBox width="100%" height="100%">
            <mx:Button label="Button" click="button1_clickHandler(event)"/>
        <mx:Repeater id="rep" dataProvider="{mainMenuXML.item}">
            <flexlib:WindowShade label="{rep.currentItem.@value}" width="50%" opened="{rep.currentItem.@open}">
                <mx:Label text="xxxxxxxxxx" />
            </flexlib:WindowShade>
        </mx:Repeater>
    </mx:VBox>
    Now in button1 click handler I am appending child in XML(mainMenuXML) resulting adding one more windowshade instance. But the problem is it opens all the windowshade intances.
    I need to maintain the opened states after adding a new windowshade instance. For example: Initially I get 3 windoshades with labels: abc, xyz, lmn all opened. Now I close the xyz windowshade instance(by clicking on the header) Now I click on button which appends child in mainMenuXML and also add a windowshade instance with some label "pqr". But now I see all the windowshade instances opened. But it should be like abc, lmn, pqr should be opened & xyz closed(property opened="false").
    Please help me in maintaining the opened true/false state of windowshade instances.
    I tried to add a property in dataprovider Bindable to opened property of windhowshade but didn't worked for me.
    Thanks in advance

    Create a loop and updated each table separately.
    Other than that you question is too vague to give a better reply.

Maybe you are looking for