CommandLink ,in action use dynamic variable

<h:commandLink action="#{appmsg.commandAction1}" value="#{appmsg.commandValue1}">
</h:commandLink>
appmsg is backingBean,"commandAction1" is a setCommandAction1 getCommandAction1 variable,not a method, I put a value like "#{app1.method1}" string to commandAction1 on application ,
eg:
appmsg.setCommandAction1("#{app1.method1");
<h:commandLink action="#{appmsg.commandAction1}" value="#{appmsg.commandValue1}">
</h:commandLink>
the action infact is #{app1.method1}
how I to do?

However I can't understand why you want to do so,
you can do so by developping your own Application Action Listener.
The default Application Action Listener does something like as follows:MethodBinding bind = ((ActionSource) event.getComponent()).getAction();
String outcome = (String)bind.invoke(fctx, null);
nhandler.handleNavigation(fctx,bind.getExtressionString(),outcome);
fctx.renderResponse();Instead, your Application Action Listener may do as follows:UIComponent comp = (UIComponent)event.getComponent();
String actionString = (String)comp.getAttributes().get("action");
String action  = (String)app.createValueBinding(actionString).getValue(fctx);
MethodBinding bind = (MethodBinding)app.createMethodBinding(action,null);
String outcome = (String)bind.invoke(fctx, null);
nhandler.handleNavigation(fctx,bind.getExtressionString(),outcome);
fctx.renderResponse();

Similar Messages

  • Alternative to using dynamic variable / NOW () in Content FILTER

    Good morning all,
    Could someone suggest an alternative to using NOW () in the WHERE clause of LTS? Using ExpirationDate>NOW() works, but unfortunately, this request can't be cached (because reports using dynamic statements using NOW () and TODATE () don't get cached).
    I've identified a possible solution - creating a variable that would use first day of current month with this Initialization block:
    SELECT LAST_DAY (ADD_MONTHS (CAST(SUBSTR(SYSDATE,1,10) AS DATE), -1))+1 FROM TIMEDIM_TABLE WHERE CAST(SUBSTR(SYSDATE,1,10) AS DATE)=CALENDAR_DATEAs a result the variable is showing: TIMESTAMP '2009-05-01 00:00:00' in Default Initializer field. This seems to be working - I'm just not sure why not all he reports get cached.
    My question is - is this valid way for this and is there a better way to accomplish this?

    Hy Wildmight,
    Here an article :
    Why a Query is Not Added to the Cache ?
    http://gerardnico.com/wiki/dat/obiee/bi_server/cache/obiee_bi_server_why_no_cache
    If you use a repository variable, the cache work and the entry will be deleted next time you update it.
    Success
    Nico

  • Tween using dynamic variable

    So I'm a huge supporter of trying to make my code reusable.
    I'm trying to build a tween with actionscript that I can use on a
    number of different object, depending on what variable I load into
    the function. However, I'm having a hard time writing the code.
    So, I have a button, that calls a function:
    on(rollOver){
    _root.fadeLogo(1, "out")
    on(rollOut, dragOut){
    _root.fadeLogo(1, "in")
    Then I have a function in the root of the movie:
    function fadeLogo(logoNumber, fadeEffect){
    if (fadeEffect=="out"){
    fadeClientLogo = new
    Tween("clientGridMC.logoHolder"+logoNumber, "_alpha",
    Normal.easeOut, "clientGridMC.logoHolder"+logoNumber+"._alpha", 0,
    .1, true)
    }else{
    fadeClientLogo = new
    Tween(("clientGridMC.logoHolder"+logoNumber, "_alpha",
    Normal.easeOut, "clientGridMC.logoHolder"+logoNumber+"._alpha",
    100, .1, true)
    However, this doesn't seem to do anything. I need this for a
    project going out on Tuesday. Any help would be GREAT! I would hate
    to have to simply duplicate this code 16 times simply to change a
    few numbers.

    Great call LuigiL,
    I'm able to get all of this to work until I want to construct
    the path to the Movie Clip and send it to the function that will
    actually move the object. I am able to pass the correct path all
    the way through the function and will even trace back out
    correctly. For some reason if I try to tag on more to the path it
    dies and does nothing.
    Any ideas?
    // Function doing the moving.
    function linkInvoker(whoAmI, myBG){
    new Tween(myBG, "_xscale", Regular.easeOut, 0, 177, .15,
    true);
    new Tween(myBG, "_alpha", Regular.easeOut, 0, 75, .15,
    true);
    new Tween(whoAmI, "_x", Regular.easeOut, 0, 8, .25, true);
    trace(whoAmI+ " : "+myBG);
    // The call from a button
    mainLinks_mc.My_btn.onRollOver = function() {
    var myBG = this+".bttn_BG";
    linkInvoker(this, myBG);
    }

  • Static Variable using Dynamic Variable

    I have a need to display different variations of the current date across multiple reports - for example: YYYYMM, MMYYYY, YYYYDD, etc.
    I thought I could create an initialization block that maps three variables containing - YYYY, MM and DD.
    In the Static Variable I was going to do the different concatenation of these variables. I see in the Static Variable it allows me to go in and select repository variables in the Expression Builder, so if had two Dyanmic Variables (VarYYYY and VarMM) I select these for my new Static Variable and concatenate them (Valueof(VarYYYY) || Valueof(VarMM).
    However, when I go to the report and display this variable it displays just the text above, treating it like a string value, so all I see in the report is:
    Valueof("VarYYYY") || Valueof("VarMM")
    I am referencing in the report with the syntax
    @{biServer.variables['StaticVarName']}
    Is there a reason why it does not display the variable values?
    Thanks

    mmm some solution could be to write the same insert with decode/case statement and put there the conditions that you want.
    maybe something like this:
    SQL> ed
    Wrote file afiedt.buf
      1  begin
      2    for i in 1..10 loop
      3      insert into t1 (col1,col2,col3)
      4        values (i,
      5                decode (mod (i,2),0,i,null),
      6                decode (mod (i,3),0,i,null));
      7    end loop;
      8* end;
    SQL> /
    PL/SQL procedure successfully completed.
    SQL> select * from t1;
          COL1       COL2       COL3
             1
             2          2
             3                     3
             4          4
             5
             6          6          6
             7
             8          8
             9                     9
            10         10
    10 rows selected.
    SQL> truncate table t1;
    Table truncated.
    SQL> insert into t1 (col1,col2,col3)
      2    select rownum,
      3           decode (mod (rownum,2),0,rownum,null),
      4           decode (mod (rownum,3),0,rownum,null)
      5    from dual
      6  connect by rownum <=10;
    10 rows created.
    SQL> select * from t1;
          COL1       COL2       COL3
             1
             2          2
             3                     3
             4          4
             5
             6          6          6
             7
             8          8
             9                     9
            10         10
    10 rows selected.forgot that you are not using anymore the loop :)
    Message was edited by:
    Delfino Nunez

  • Using Dynamic Variable Names

    I am hoping someone can help me out with this.
    I am creating my own record that has the format (id_1, title_1, id_2, title_2...id_50, title_50). I was wondering if there was a way that I could iteratively assign values to each attribute in this record without having to explicitly type out each assignment (partially because the number of columns will vary).
    Any help is greatly appreciated!
    Thx

    I did not think that there was a way to access the attributes within a record/object by using an offset or an index (i.e. set the 4th attribute of the record to 'XXX').
    Here might be a better example for my problem. Let's say the "object" is a car. The car can have 1 to N options associated with it (we'll use 3 for this example). Each option has an ID associated with it as well as text that describes that option. Each car should only have one record that describes all of it's options collectively.
    car_id Opt1_id Opt1_Text Opt2_id Opt2_Text Opt3_id Opt3_text
    'car1' 25 'CD Player' 41 'A/C' 11 '4X4'
    'car2' 25 'CD Player' 40 NULL 10 '2X4'
    So how can I build these records without having to directly assign each value as show below?
    car(1).car_id := 'car1';
    car(1).Opt1_id := 25;
    car(1).Opt1_Text := 'CD Player';
    car(1).Opt2_id = 41;
    car(1).Opt2_Text := 'A/C';
    car(1).Opt3_id := 11;
    car(1).Opt3_Text := '4X4';
    Desired solution:
    car(1).car_id := 'car1';
    For i IN 1..3
    LOOP
    car(1).Opt||i||_id := <some id>;
    car(1).Opt||i||_Text := <some text>;
    END LOOP;

  • Problem using dynamic variable as HashMap key

    I have created a HashMap called instantHashMap and loaded it with data from a query.
    I can load a variable with a value for the HashMap key and successfully output the HashMap value:
    <c:set var = "gameno" value="150" />
    <c:out value = "${instantHashMap[gameno]}" />
    But when I load my variable value from my data like this...
    <c:set var = "gameno" value="${rvo.gameNo}" />
    <c:out value = "${instantHashMap[gameno]}" />
    ...it doesn't work.
    My loaded variable value is correct because this statement does work and reflects the data obtained from my query:
    <c:out value = "${gameno}" />
    Could rvo.gameNo be the wrong data type or something?

    My loaded variable value is correct because this statement does work >and reflects the data obtained from my query:In which case, check if your map contains a key which is the loaded variable value.
    ram.

  • Dynamic variable Time for Select

    Hi,
    I try to develop some scripts but always I have the same problem , when I try to put in a Select instruction the variable Time, it doesn´t work correctly (for example):
    *SELECT(%example%,"ID","TIME","[ID]='%TIME_SET%' ")
    It doesn´t read correctly the variable Time_Set.
    Have you got any idea to try to do selects using dynamic variable?
    Thanks for all.

    Hi,
    Dynamic variables like %TIME_SET% do not interact very well with the compiled default logic (LGX files) when it is run after a data send. If you look at the Default.LGX file, you will notice that your *SELECT statement does not appear there because that *SELECT statement has already been compiled. That is why the logic works when it is run via the debugger (because the LGF file is getting executed at run time) and it does not work when it is run via a data send (because the LGX is being executed).
    What you will need to do is:
    1. Create a another logic file (for example: Calculation1.LGF) and copy the text from the Default.LGF to this new logic file.
    2.  Place the following text in the Default.LGF file:
    *RUNLOGIC
    *LOGIC=Calculation1.LGF
    *ENDRUNLOGIC
    3. Validate and save the Default.LGF file
    Now try running the logic after a data send and see if that works.
    Good luck,
    John

  • Dynamic Variable Names in OpenScript

    Is there a way to use dynamic variable names? What I mean by this is that the variable name in the file could be:
    Name1, Name2, Name3, etc.
    I may want to loop through these by saying something like:
    For i = 0; i < iLoop; i++
    String sFieldName = "{{ViewList.Name" + Integer.toString(i) + "}}";
    JOptionPane.showMessageDialog(null, "sFieldName: " + "{{ViewList.{{sFieldName}}}}");
    I don't want it to use the literal string of {{ViewList.Name1}}, but rather, I want to use the value from the DataBank for Name1. Thanks.
    -John

    Nishanth,
    Thanks for your suggestion. Unfortunately, this is not a simple variable replacement. I want the name of the variable to be dynamic in nature. Imagine that I have 5 variables in the files named:
    Name
    FoodPref1
    FoodPref2
    FoodPref3
    FoodPref4
    I would like to loop through these and construct the variable name dynamically so it would be something similar to:
    for i=1 to 4; i++
    sFoodPrefVar = "FoodPref" + i;
    getVariables().set("FoodPref",sFoodPrefVar);
    JOptionPane.showMessageDialog(null, "Your Food Pref is: " + {{FoodPref}} + "\n");
    This is pseudo code, but it would theoretically loop through the 4 food preferences. Thanks.
    -John

  • Dynamic Variable Refreshment

    Hi All,
    I am facing a problem with the dynamic variable refreshment. I have used dynamic variable in the where clause in the content of a table in the BMM layer.
    But according to the refresh time the variable is getting refreshed in the RPD but the value in the Webcat is not reflecting at the same time. It is taking time to get reflected in the Webcat reports and the time is not specific. I have clear the cache in the Webcat but getting no result out of it. I think the value of the variable is taking time to get reflected in the content of the table.

    Might be that the presentation server cache is giving you trouble, try disabling it:
    http://obiee101.blogspot.com/2008/12/obiee-bypassing-presentation-web-cache.html
    regards
    John
    http://obiee101.blogspot.com

  • Using bind variable in dynamic where clause and concatenate with query

    Hi,
    In my procedure i am framing where clause dynamically with bind variable,When i am concatenate this with my sql query for REF CURSOR i got sql command not properly ended exception.
    Is it possible to pass values to the bind variable through the dynamic variable/value?
    Please advise
    Thanks in advance
    Siva
    IF in_applicationId IS NOT NULL THEN
              optional_where := optional_where || ' AND a.APPLICATION_ID like '||':e%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'||',in_queue_id'||',in_applicationId';
         END IF;
    My query is like this
    open Out_Main FOR SelectQuery USING optional_using

    Thanks for reply,
    In my procedure, i suppose to frame the where clause with bind dynamically according to the input parameters. so that i am framing the values of the bind variables also dynamically like this,
    Please advise...
    IF in_assignedAppFlag IS NOT NULL THEN
              IF in_assignedAppFlag = 'Y' THEN
                   optional_where := optional_where || ' AND b.ASSIGNED_TO = :b' ;
              optional_using := ' in_appFuncGroup'||',in_currentUserID';          
              ELSe
                   IF in_isSupervisor = 0 THEN
                        optional_where := optional_where || ' AND (b.ASSIGNED_TO = :b'||' OR b.ASSIGNED_TO = ''-1'' OR b.ASSIGNED_TO IS NULL)';
              optional_using := ' in_appFuncGroup'||',in_currentUserID';
                   END IF;
              END IF;
         ELSE
              IF in_isSupervisor = 0 THEN
                   optional_where := optional_where || ' AND (b.ASSIGNED_TO = :b'||' OR b.ASSIGNED_TO = ''-1'' OR b.ASSIGNED_TO IS NULL)';
                   optional_using := ' in_appFuncGroup'||',in_currentUserID';
              END IF;
         END IF;
         IF in_appFuncGroup IS NOT NULL THEN
              optional_where := optional_where || ' AND e.APP_FUNC_GROUP= :c';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup';
         END IF;
         IF in_queue_id IS NOT NULL THEN
              optional_where := optional_where || ' AND b.QUEUE_ID = :d';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'||',in_queue_id';
         END IF;
         IF in_applicationId IS NOT NULL THEN
              optional_where := optional_where || ' AND a.APPLICATION_ID like '||':e%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'||',in_queue_id'||',in_applicationId';
         END IF;
         IF in_sourceCode IS NOT NULL THEN
              optional_where := optional_where || ' AND e.APP_SOURCE_CODE like '||':f%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode';
         END IF;
         IF in_logo IS NOT NULL THEN
              optional_where := optional_where || ' AND appProds.PRODUCT_TYPE like '||':g%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode'||',in_logo';
         END IF;
         IF in_firstName IS NOT NULL THEN
              optional_where := optional_where || ' AND upper(a.FIRST_NAME) like upper(:h%)';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode'||',in_logo'||',in_firstName';
         END IF;
         IF in_surName IS NOT NULL THEN
              optional_where := optional_where || ' AND upper(a.SURNAME) like upper(:i%)';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode'||',in_logo'||',in_firstName'||',in_surName';
         END IF;
         IF in_retreival_id IS NOT NULL THEN
              optional_where := optional_where || ' AND e.RETREIVAL_ID like :j%';
              optional_using := ' in_appFuncGroup'||',in_currentUserID'||',in_appFuncGroup'
              ||',in_queue_id'||',in_applicationId'||',in_sourceCode'||',in_logo'||',in_firstName'||',in_surName'||',in_retreival_id';
         END IF;

  • How to make a default value by using dynamic actions

    Hi,
           I want to default a field nationality in infotype 0002 as a great britan, using dynamic actions but unable to go ahead. Any help regarding this really appreciate.
    Regards
    Niranjan

    Hi,
    I need some guidance around creating dynamic action with default value, Please guide me through.
    I am aware I can set default values for new infotype, but I need to set default value for same infotype, let me explain the scenario.
    Currently employee is on one pension scheme which is called NE1 and now we are moving this employee to CRESP Pension Scheme.
    When employee is in NE1, his IT0071 has got a opt in field with a flag on, when the same employee is moved from NE1 pension scheme to CRESP Pension scheme, his new IT0071 record should have the same opt in field with a flag on, I want it to set this flag automatically using dynamic action. I dont want to update this field manually, while moving from NE1 to CRESP.
    Currently the below dynamic  action is coded when employees are being moved form NE1 to CRESP, but now they will have a opt in flag which should appear automatically, What needs to be done to make this happen?
    Please let me know if I set default value for the Opt in field for the same infotype.
    . When employees are being moved from NE1 to CRESP pension scheme we currently use a dynamic action as show below:
    0071                      04      10      I        INS,0069
    0071                      04      20      W       P0069-BEGDA=P0071-BEGDA
    0071                      04      30      W       P0069-ENDDA=P0071-ENDDA
    0071                      06      1        F        DYNACT_PAE031(ZHRPROG016)
    Also if it is not possible via dynamic action could you please explain how to create it using user exit, I am not an ABAPer.
    Your help is very much appreciated.
    Kind Regards,
    SK

  • Saving result from sp_executesql into a variable and using dynamic column name - getting error "Error converting data type varchar to numeric"

    Im getting an error when running a procedure that includes this code.
    I need to select from a dynamic column name and save the result in a variable, but seem to be having trouble with the values being fed to sp_executesql
    DECLARE @retval AS DECIMAL(12,2)
    DECLARE @MonthVal VARCHAR(20), @SpreadKeyVal INT
    DECLARE @sqlcmd AS NVARCHAR(150)
    DECLARE @paramdef NVARCHAR(150)
    SET @MonthVal = 'Month' + CAST(@MonthNumber AS VARCHAR(2) );
    SET @SpreadKeyVal = @SpreadKey; --CAST(@SpreadKey AS VARCHAR(10) );
    SET @sqlcmd = N' SELECT @retvalout = @MonthVal FROM dbo.CourseSpread WHERE CourseSpreadId = @SpreadKeyVal';
    SET @paramdef = N'@MonthVal VARCHAR(20), @SpreadKeyVal INT, @retvalout DECIMAL(12,2) OUTPUT'
    --default
    SET @retval = 0.0;
    EXECUTE sys.sp_executesql @sqlcmd,@paramdef, @MonthVal = 'Month4',@SpreadKeyVal = 1, @retvalout = @retval OUTPUT;
    SELECT @retval
    DECLARE @return_value DECIMAL(12,2)
    EXEC @return_value = [dbo].[GetSpreadValueByMonthNumber]
    @SpreadKey = 1,
    @MonthNumber = 4
    SELECT 'Return Value' = @return_value
    Msg 8114, Level 16, State 5, Line 1
    Error converting data type varchar to numeric.

    Please follow basic Netiquette and post the DDL we need to answer this. Follow industry and ANSI/ISO standards in your data. You should follow ISO-11179 rules for naming data elements. You should follow ISO-8601 rules for displaying temporal data. We need
    to know the data types, keys and constraints on the table. Avoid dialect in favor of ANSI/ISO Standard SQL. And you need to read and download the PDF for: 
    https://www.simple-talk.com/books/sql-books/119-sql-code-smells/
    >> I need to select from a dynamic column name and save the result in a variable, but seem to be having trouble with the values being fed to sp_executesql <<
    This is so very, very wrong! A column is an attribute of an entity. The idea that you are so screwed up that you have no idea if you want
    the shoe size, the phone number or something else at run time of this entity. 
    In Software Engineering we have a principle called cohesion that says a model should do one and only one task, have one and only one entry point, and one and only one exit point. 
    Hey, on a scale from 1 to 10, what color is your favorite letter of the alphabet? Yes, your mindset is that level of sillyity and absurdity. 
    Do you know that SQL is a declarative language? This family of languages does not use local variables! 
    Now think about “month_val” and what it means. A month is a temporal unit of measurement, so this is as silly as saying “liter_val” in your code. Why did you use “sp_” on a procedure? It has special meaning in T-SQL.  
    Think about how silly this is: 
     SET @month_val = 'Month' + CAST(@month_nbr AS VARCHAR(2));
    We do not do display formatting in a query. This is a violation of at the tiered architecture principle. We have a presentation layer. But more than that, the INTERVAL temporal data type is a {year-month} and never just a month. This is fundamental. 
    We need to see the DDL so we can re-write this mess. Want to fix it or not?
    --CELKO-- Books in Celko Series for Morgan-Kaufmann Publishing: Analytics and OLAP in SQL / Data and Databases: Concepts in Practice Data / Measurements and Standards in SQL SQL for Smarties / SQL Programming Style / SQL Puzzles and Answers / Thinking
    in Sets / Trees and Hierarchies in SQL

  • Using bind variables (in & out) with dynamic sql

    I got a table that holds pl/sql code snippets to do validations on a set of data. what the code basically does is receiving a ID and returning a number of errors found.
    To execute the code I use dynamic sql with two bind variables.
    When the codes consists of a simpel query, it works like a charm, for example with this code:
    BEGIN
       SELECT COUNT (1)
       INTO :1
       FROM articles atl
       WHERE ATL.CSE_ID = :2 AND cgp_id IS NULL;
    END;however when I get to some more complex validations that need to do calculations or execute multiple queries, I'm running into trouble.
    I've boiled the problem down into this:
    DECLARE
       counter   NUMBER;
       my_id     NUMBER := 61;
    BEGIN
       EXECUTE IMMEDIATE ('
          declare
             some_var number;
          begin
          select 1 into some_var from dual
          where :2 = 61;
          :1 := :2;
          end;
          USING OUT counter, IN my_id;
       DBMS_OUTPUT.put_line (counter || '-' || my_id);
    END;this code doesn't really make any sense, but it's just to show you what the problem is. When I execute this code, I get the error
    ORA-6537 OUT bind variable bound to an IN position
    The error doesn't seem to make sense, :2 is the only IN bind variable, and it's only used in a where clause.
    As soon as I remove that where clause , the code will work again (giving me 61-61, in case you liked to know).
    Any idea whats going wrong? Am I just using the bind variables in a way you're not supposed to use them?
    I'm using Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit

    Correction. With execute immediate binding is by position, but binds do not need to be repeated. So my statement above is incorrect..
    You need to bind it once only - but bind by position. And the bind must match how the bind variable is used.
    If the bind variable never assigns a value in the code, bind as IN.
    If the bind variable assigns a value in the code, bind as OUT.
    If the bind variable assigns a value and is used a variable in any other statement in the code, bind as IN OUT.
    E.g.
    SQL> create or replace procedure FooProc is
      2          cnt     number;
      3          id      number := 61;
      4  begin
      5          execute immediate
      6  'declare
      7          n       number;
      8  begin
      9          select
    10                  1 into n
    11          from dual
    12          where :var1 = 61;       --// var1 is used as IN
    13 
    14          :var2 := n * :var1;     --// var2 is used as OUT and var1 as IN
    15          :var2 := -1 * :var2;    --// var2 is used as OUT and IN
    16  end;
    17  '
    18          using
    19                  in out id, in out cnt;  --// must reflect usage above
    20 
    21          DBMS_OUTPUT.put_line ( 'cnt='||cnt || ' id=' || id);
    22  end;
    23  /
    Procedure created.
    SQL>
    SQL> exec FooProc
    cnt=-61 id=61
    PL/SQL procedure successfully completed.
    SQL>

  • How do I use a dynamic variable from a prolog script?

    I have my test broken in to three scripts, a login, an update, and a logout. There is a dynamic variable, SERVICE_VIRTUAL_CLIENT, from the login script that I need to use in the update script, but I can't figure out how to do it. Any help would be appreciated.
    Edit: I forgot to mention that the login script is only run in the prolog portion of the UDP.
    Scott
    Message was edited by: scottmorgan

    Scott,
    You would do this the same way you would in a stand-alone script. Create the variable pattern in the login in script and name the variable. Save the login script and open the other script and select the parameter where you need the value. Set the parameter value to {{variableNameFromLogin}} (Variables are transferred from one script to the next in a UDP).
    I hope this makes sense

  • Is it possible to change LOV definition using dynamic action?

    Hi,
    I have a multi-select LOV page item, P27_MULTI_CLASS_CODE, defined as below.  On page load, this list only contains values based on what has been passed to P27_OLO_CODE or P27_OLO_CODE_SW.
    SELECT DISTINCT c.class_code d, c.class_code r
      FROM ORGANIZATION o,
           POSITION p,
           CLASS c
    WHERE o.org_wk = p.org_wk
       AND p.class_wk = c.class_wk
       AND o.org_active_flag = 'Y'
       AND p.pos_active_flag = 'Y'
       AND c.class_active_flag = 'Y'
       AND (o.olo_code = :P27_OLO_CODE
            OR o.olo_code = :P27_OLO_CODE_SW)
    ORDER BY c.class_code ASC
    Before submitting the page, I would like the LOV definition of P27_MULTI_CLASS_CODE to change to the following (similar query without reference to P27_OLO_CODE or P27_OLO_CODE_SW) based on whether the user selects checkbox item, P27_ALLOW_SW.   By doing this, P27_MULTI_CLASS_CODE would contain a full range of values rather than limited values.
    SELECT DISTINCT c.class_code d, c.class_code r
      FROM ORGANIZATION o,
           POSITION p,
           CLASS c
    WHERE o.org_wk = p.org_wk
       AND p.class_wk = c.class_wk
       AND o.org_active_flag = 'Y'
       AND p.pos_active_flag = 'Y'
       AND c.class_active_flag = 'Y'
    ORDER BY c.class_code ASC
    I wanted to avoid writing Javascript.  Is this possible using dynamic actions...or at least somehow refresh P27_MULTI_CLASS_CODE so that it ignores P27_OLO_CODE and P27_OLO_CODE_SW?
    I've tried creating a dynamic action to clear the value of  P27_OLO_CODE or P27_OLO_CODE_SW, in hope it would trigger P27_MULTI_CLASS_CODE to display all values, but it has not been successful.  Any ideas?
    APEX 4.2

    I was able to resolve by changing the SQL statement to P27_MULTI_CLASS_CODE.  Note:  I also included an additional condition.
    SELECT DISTINCT c.class_code d, c.class_code r
      FROM ORGANIZATION o,
           POSITION p,
           CLASS c
    WHERE o.org_wk = p.org_wk
       AND p.class_wk = c.class_wk
       AND o.org_active_flag = 'Y'
       AND p.pos_active_flag = 'Y'
       AND c.class_active_flag = 'Y'
       AND (:P27_ALLOW_SW = 'Y'
            OR (o.olo_code =  :P27_OLO_CODE
                OR o.olo_code = :P27_OLO_CODE_SW)
       AND (:P27_PAY_PLAN IS NULL
             OR p.pay_plan = :P27_PAY_PLAN)
    ORDER BY c.class_code ASC
    I also changed the Cascading LOV Parent Item(s) value to:  P27_OLO_CODE,P27_OLO_CODE_SW,P27_PAY_PLAN,P27_ALLOW_SW.  Optimize Refresh = No, since a change in any one of these values should trigger refresh of LOV.
    The Dynamic Action was also modified to NULL out P27_OLO_CODE,P27_OLO_CODE_SW when P27_ALLOW_SW was enabled.
    So far, so good!  Thanks for your suggestions Tom and Howard!

Maybe you are looking for

  • Put html tag in xml genreted with strings panel

    Hello, I created an multilanguage application with the "strings "panel. My customer need to put some words in italic inside the dynamic textfield. So I used <i> tag or cdata tag insied the xml, but nothing works, even if I put the textfield in "html"

  • Video preview not working, I can see only white screen.

    Hello, I have been using Adobe Premiere on my Vista64 for a while, but few days ago I started having problems with previewing video. I can see only white screen, which doesnt react on anything I do in premiere (trying to preview movie, add grids etc.

  • Pulseaudio and USB Dac

    How do I get pulseaudio to see my USB dac? It keeps playing sound through the sound card only. I've added "load-module module-udev-detect" to default.pa, and changed my ~/.asoundrc to include: pcm.pulse { type pulse ctl.pulse { type pulse pcm.!defaul

  • What is the ipod 4 new model, I mean look at the walmart site, it says (new model) what does that mean?

    what is the ipod 4 new model, I mean look at the walmart site, it says (new model) what does that mean? Look at this link :  http://www.walmart.ca/canada-estore/search/searchcontainer.jsp?_DARGS=/canada-es tore/search/fragments/cataloghierarchy.jsp I

  • Function module to push 66 to 53

    Hi, Please let me know the function module that pushes the idocs from 66 to 53 status. Tried debugging RBDAPP01 program, but too many function modules exists. Not able to locate the right one.Kindly help me gurus. Regards, Lakshminarasimhan.N