Apex 4 Cascading LOV's how to set a child LOV back to null return value

Hi,
My problem is I am using the new Dynamic Actions to implement Cascading LOV functionality in Apex 4 which means not having to submit the page to update child LOVs after parent LOV changes.
What I am finding is that when you change the parent LOV value then the child LOV (which has a null return value) is not defaulting to the null return value (in my case no selection should return -1) if its list is filtered to a different set of values which doesnt have a valid selection. The child LOV is left without a selection when I need it to default back to the null return value (-1, representing all values).
Also I was hoping to do this before the page is submitted so the filtering down the hierarchy of LOVs will work where the child is null (-1, meaning all values) and in turn its child LOV(s) will filter also from the null child value.
Any help would be much appreciated.
Thanks

Hi 804641,
I'm not sure if I get your problem and I tried to reproduce it.
http://apex.oracle.com/pls/apex/f?p=2672:6 is my example with a cascading LOV where I have also defined a dynamic action which fires when P6_EMPNO changes and it shows the current selection.
Maybe it helps if you setup an example on apex.oracle.com and provide the workspace/user/pwd so that I can have a look. I'm also not sure about your sentence "using the new Dynamic Actions to implement Cascading LOV functionality", because dynamic actions are not needed for cascading LOVs. It's a feature of the item types themselves where you just have to set the "Cascading LOV Parent Item(s)" attribute.
Regards
Patrick
My Blog: http://www.inside-oracle-apex.com
APEX 4.0 Plug-Ins: http://apex.oracle.com/plugins
Twitter: http://www.twitter.com/patrickwolf

Similar Messages

  • How to set Dropdown list in tablen whith others Dropdown values in each row

    how to set Dropdown list in tablen whith others Dropdown values in each row of the table

    hi ,
    You have to add the parent element before adding data to the child node ...you follow the below steps it will work
    1) Take ContextStructure as follows ...
    tabledata (valuenode)
        ddownbyindex( value node) --within the tabledata node
             value (attribute)
    2)Binding to your layout
      tabledata (node) ---bind this to the dataSource property of your  table
          ddownbyindex( node)
                Value (attribute)--bind to the texts property of you DDbyIndex
    3)In wdinit() method add the following code
         IPrivate<Your view name>.ITabledataElement tabledataElement =wdContext.createTabledataElement();
        wdContext.nodeTabledata().addElement(tabledataElement);
        for(int i=0;i<5;i++)
         IPrivate<Your viewname>.IDdownbyindexElement ddbyindexElement=wdContext.createDdownbyindexElement();
             ddbyindexElement.setValue("Value"+i);
             wdContext.nodeDdownbyindex().addElement(ddbyindexElement);
    And set the cardinality property of the table node as 0..n
    and dropdownbyinex node to 1..n
    You try it ...
    Regards
    Madhavi
    Edited by: madhavi kotra on Sep 2, 2008 6:00 PM

  • How to trap null return values from getters when using Method.invoke()?

    Hi,
    I am using Method.invoke() to access getters in an Object. I need to know which getters return a value and which return null. However, irrespective of the actual return value, I am always getting non-null return value when using Method.invoke().
    Unfortunately, the API documentation of Method.invoke() does not specify how it treats null return values.
    Can someone help?
    Thanks

    What do you get as a result?I think I know what the problem is.
    I tested this using following and it worked fine:
    public class TestMethodInvoke {
    public String getName() {
    return null;
    public static void main(String args[]) throws SecurityException, NoSuchMethodException, IllegalArgumentException, IllegalAccessException, InvocationTargetException {
    Object o = new TestMethodInvoke();
    Class cls = o.getClass();
    Method m = cls.getMethod("getName", (Class[]) null);
    Object result = m.invoke(o, (Object[])null);
    if (result == null) {
    System.err.println("OK: Return value was null as expected");
    else {
    System.err.println("FAILED: Return value was NOT null as expected");
    However, when I use the same technique with an EJB 3.0 Entity class, the null return value is not returned. Instead, I get a String() object. Clearly, the problem is the the EJB 3.0 implementation (Glassfish/Toplink) which is manipulating the getters.
    Regards
    Dibyendu

  • How much money would i get back if i returned a droid razer with nothing wrong to it

    how much money will I get back if I return a droid razor with nothing wrong with it

        Hi julann37!
    Are you looking to sell your Droid RAZR? Do you have another device besides that one to use? You can visit http://vz.to/1mfkksD to check the value.
    Thanks,
    ChristinaB_VZW
    Follow us on Twitter @VZWSupport

  • How to set a date type variable to null, nothing or such

    I created an User Defined Type that holds a Deadline property which is date type. Whenever there is no Deadline set yet, I would like such property to be set to Null, Nothing or such. I noticed that if I just Dim a Date Type variable its value will be
    already set to 12:00 AM, and the same value takes place if I set the variable to a blank cell value. Any ideas to get around of this problem?
    Jorge Barbi Martins ([email protected])

    A variable of type Date cannot be empty. Its default value is 0, which corresponds to Midnight on 30 December 1899.
    If you want to be able to make it empty, declare it as Variant instead of as Date. You can then set its value to Null.
    Regards, Hans Vogelaar (http://www.eileenslounge.com)

  • How to populate right side of Shuttle with display/return values?

    Hello,
    I know, that the proper way to populate the right side of shuttle is that:
    declare
         v_list     apex_application_global.vc_arr2;
    begin
         select profile_name return_value
           bulk     collect
           into     v_list
           from     user_profiles
          where     user_id = :p61_user_id;
         return (apex_util.table_to_string (v_list));
    end;It is comfortable for the user to see the name of the profile.
    However, I need a profile_id as a return value, like I have it on the left side of the shuttle.
    The left side of the shuttle is populated with a select list with display/return values, as you know.
    I need both sides of the shuttle to return profile_id in order to create a merge.
    How is it possible to populate the right side of the Shuttle with display/return values?

    All you have to do is to use the subset of shuttle query to assign value to the right side shuttle.
    http://apex.oracle.com/pls/apex/f?p=50942:95
    I have created a dummy page with shuttle query
    SELECT ename, empno FROM emp ORDER by 1then I have defined a pl-sql before header process to assign values to shuttle variable
    using the code
    begin
    :P95_SHUTTLE := '7566:219:7900:7782:90';
    end;since 90 is not one the result set of the shuttle query it is getting displayed as number, and for others it is displaying the text. Thanks.
    --Manish                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • PL/SQL  on delete cascade..   ( how  to view the child record deleted..?)

    Hai
    i have 70 tables integrated with foreign and child key constraints. i have on delete cascade for all the child tables. if i delete the parent table automatically child table record get deleted.
    Kindly tell me how can i check howmany child record has been deleted ..? how can i monitor this...?
    one thing i can do... i can make count of child table before and after...
    is there anyother way..?
    S

    Peter,
    I subscribe to the general consensus around trigger usage. Allthough I allways diffentiate between triggers that,
    - perform pl/sql with embedded DML (that is: delete, insert, update)
    versus triggers
    - that perform pl/sql with embedded queries only.
    The latter use of triggers is good (in my opinion), and most frequently used to enforce (non declarable) data integrity constraints.
    The former use of triggers is bad. Because it makes things happen automagically.
    Just google "asktom triggers are evil", you'll find statements such as:
    ~quote
    because things happen automagically
    because side effects are bad
    because explicit linear code is more maintainable then "happens as a by product of something in the background"
    magic should be avoided. Experience tells me this.
    ~quote
    And to me a CASCADE DELETE clause on a foreign key definition, is a TRIGGER. Allbeit not one for which you had to write CREATE TRIGGER statements, but one that you can declaratively introduce. And this trigger holds embedded DML, it is of the former case, and is therefor bad.
    You the designer of the application may be aware that you have your FK's as cascade delete. But your successor(s) might not be aware of this when they write maintenance code to delete Orders. They might be expecting the database to throw them an FK violation message when they try to delete an Order that still has Lines attached to it.
    Everybody knows the effect of an INSERT, a DELETE, an UPDATE. But the moment you've introduced triggers with embedded DML in them, the effect of these three well known primitive SQL statements suddenly becomes unknown. With triggers you can create any effect for any of these three primitives, that you want. And more often than not other people maintaining your codebase later on in the future, do not realize these side effects happen, because they didn't check the presence of any triggers, nor investigated the side effects caused by them.
    Btw. for exactly the same reasoning I consider use of DEFAULT-clause on table columns, or even use of (fixed length) CHAR datatype, evil also. Again they are in effect declarative triggers with side effects. Allbeit that their side effects usually are less worse than those caused by handwritten triggers with embedded DML.
    Toon

  • How to set phone keypad lang back to English?

    Hello all,
    Yesterday had to restore my iPhone 6 plus 'cause it was taking forever to sync new songs into it. Anyway the restore and sync were success.
    Then I discovered this little oddity (see attached pic).
    If I add a new contact > add a new number > tap the + * # key (to get the + sign), you notice above the * and # keys the two keys (4 & 6 position) are in Chinese, how to I change them back to English?
    Thanks.

    How long your phone rings before going to voicemail is usually a setting the carrier can change on your account.  Give your carrier's Customer Service department a call and see if they can extend the ring time.
    As for text notification:
    You can set a longer tone by going to Settings > Sounds > Text Tone and selecting a different tone option.  If you want multiple notifications if you recieve a message and keep ignoring your phone, you can get repeat notifications at two-minute intervals by going to Settings > Notification Center > Messages > Repeat Alerts and changing how many times it will repeat.

  • How to set  color of a  row depending on the value of column in JTable?

    Hi All,
    I have a JTable that add rows when the user clicks on the button. In this way there can be any no. of rows in my table. My table contains five columns. When a new row is added , it is added with new data each time. Also the data of the rows keep on changing time to time.
    My problem is that when the data value for the third column comes out to be -ve then color of the row should be red and if its value is +ve then the color of the row should be green.
    I have tried for this in the way but it is not working properly.
    public Component prepareRenderer(TableCellRenderer renderer,int rowIndex, int vColIndex)
         Component c = super.prepareRenderer(renderer, rowIndex, vColIndex);
    if(rowIndex<table.getRowCount() && change<0 )
              c.setForeground(Color.red);
              c.setFont(new Font("TimesRoman",Font.PLAIN,11));
    else if(rowIndex<table.getRowCount() && change>0)
    c.setForeground(new Color(20,220,20));
         c.setFont(new Font("TimesRoman",Font.PLAIN,11));
    return c;
    where change is the value of the third column.
    Any help is highly appreciated.
    Thanx in advance.
    Regards,
    Har Krishan

    Perhaps you'll find this link useful. It gives a general idea of how you can create and adjust your custom renderer:
    http://www.senun.com/Left/Programming/Java_old/Examples_swing/JTableExamples4.html
    Hope it helps.
    Eugene

  • How to set a boolean webservice parameter to null

    Hi all,
    is it possible to set a boolean input parameter of a webservice to null?
    False and true works well, but is there also the posibility of setting it to null?
    Greetings
    Florian

    I will try to explain.
    Our webservice has a boolean input parameter. And it acts like the follwing pseudo-code:
    IF bool_arg == null
       action1;
    ELSE IF bool_arg==false
       action2;
    ELSE IF bool_arg==true
       action3;
    ENDIF;
    With the value NULL i mean that the input paramter is not in the SOAP-XML.
    But with Visual Composer i only manage to set the value to true or false.
    I cannot find a way to set it to null (which means it is not in the SOAP-XML).
    Edited by: Florian Kandlinger on May 27, 2008 12:14 PM

  • How do set up Favorites to back up automatically (eg weekly)?

    I would like to set up my Firefox browser so that it automatically backs up my Favorites file once a week. I have been doing the manual backup, but I sometimes forget.

    Did you try Firefox Sync?
    * firefox.com/sync
    read [[What is Firefox Sync]] article for more info

  • How to set the timescape module back on home screen using ADWlauncher

    I'm using the ADW launcher replacement and with the new update there is no way to place the working widget with tiles on the homescreen again.
    There isn't a widget available either in the widget listing.
    How can I solve this so I have this common widget back on my homescreen?
    Many thanks,
    PtR

    Indeed it only works with Sony's launcher
    Don't forget to mark the Correct Answers & Helpful Answers
    "I'd rather be hated for who I am, than loved for who I am not." Kurt Cobain (1967-1994)

  • How to set a process with more than 10 item values to be changed?

    I am trying to make a "default" button where it resets the Column checkboxes to its original state but I have more than 10 iems and I cant fill them all in the 10 slots that they have. Anyone have any ideas? thanks.
    For example I have columns 1-20 and I want something like col 1-5 to be checked and col 6-20 to be unchecked as default.

    I tried to use process where i declare the new values i.e. ID=1/true, Name=0/false etc. and still nothing happens, anyone have any suggestions?

  • Applescript - how do I use the result of a library return value

    Hello.  Been using applescript for about a week.  Very new.
    I'm using the following script below using an external libarary to query mysql database on external server.  works.  gives results.  How do I save them to do something with the. 
    when I run it, the results of the call to the library show up in the results window.  that makes sense.
    ie
    {rows:1, cols:1, record_data:{{"85016   "}}}
    I want to assign the results to a variable to use it later, particularly the 85016.
    I try "set testVariable to tell db_link to do_select(theDBCommand)"
    no good.  Not sure how to do this.
    Help appreciated.
    Script follows:
    -- links to the mysql tools - thanks to http://www.j-schell.de/node/80
    set library_path to "js_aux_scripts:mysql_objects.scptd"
    set app_support to (path to application support folder) as string
    set DB_Library to (load script file (app_support & library_path))
    set db_link to new_link("lala.yadayada.com", "user", "pass", "db") of DB_Library
    -- collect the job number you want to run
    -- Get the Number
    set displayString to "Enter Job Number"
    set the theIcon to 1
    set theJobNumber to ""
    repeat
      display dialog displayString default answer theJobNumber with icon theIcon
              set theJobNumber to text returned of result
              try
                        if theJobNumber = "" then error
                        set theJobNumber to theJobNumber as number
                        exit repeat
              on error
                        set displayString to "INVALID ENTRY! " & displayString
                        set theIcon to 0
              end try
    end repeat
    -- Query the database and get the other informtion from the ticket file.
    set theDBCommand to "SELECT BaseId from SfComp where JobNo = " & theJobNumber
    tell db_link to do_select(theDBCommand)

    Usually you would assign the variable to the results of the command/function, which are inside the tell statement -for example:
    tell db_link to set testVariable to do_select(theDBCommand)
    The results are a record, where it looks like record_data is a list of lists (although your example only has one item), so for that you can specify the particular property you are intereste in, for example:
    get first item of first item of record_data of testVariable

  • How to call an Oracle Procedure and get a return value in Php

    Hi Everyone,
    Has anyone tried calling an Oracle procedure from Php using the ora functions and getting the return value ? I need to use the ora funtions (no oci)because of compatibility and oracle 7.x as the database.
    The reason why I post this here is because the ora_exec funtion is returning FALSE but the error code displayes is good. Is this a bug in the ora_exec funtion ?
    My code after the connection call is as follows:
    $cur = ora_open($this->conn);
    ora_commitoff($this->conn);
    $requestid = '144937';
    echo $requestid;
    $rc = ora_parse($cur, "begin p_ins_gsdata2
    (:requestid, :returnval); end;");
    if ($rc == true) {
    echo " Parse was successful ";
    $rc2 = ora_bind ($cur, "requestid", ":requestid", 32, 1);
    if ($rc2 == true) echo " Requestid Bind Successful ";
    $rc3 = ora_bind ($cur, "returnval", ":returnval", 32, 2);
    if ($rc3 == true) echo " Returnval Bind Successful ";
    $returnval = "0";
    $rc4 = ora_exec($cur);
    echo " Result = ".$returnval." ";
    if ($rc4 == false) {
    echo " Exec Returned FALSE ";
    echo " Error = ".ora_error($cur);
    echo " ";
    echo "ErrorCode = ".ora_errorcode($cur);
    echo "Error Executing";
    ora_close ($cur);
    The Oracle procedure has a select count from a table and it returns the number of records in that table. It's defined as:
    CREATE OR REPLACE procedure p_ins_gsdata2 (
    p_requestid IN varchar2 default null,
    p_retcode OUT varchar2)
    as
    BEGIN
    SELECT COUNT (*) INTO p_retcode
    FROM S_GSMRY_DATA_SURVEY
    WHERE request_id = p_requestid ;
    COMMIT;
    RETURN;
    END;
    Nothing much there. I want to do an insert into a table,
    from the procedure later, but I figured that I start with a select count since it's simpler.
    When I ran the Php code, I get the following:
    144937
    Parse was successful
    Requestid Bind Successful
    Returnval Bind Successful
    Result = 0
    Exec Returned FALSE
    Error = ORA-00000: normal, successful completion -- while
    processing OCI function OBNDRA
    ErrorCode = 0
    Error Executing
    I listed the messages on separate lines for clarity. I don't understand why it parses and binds o.k. but the exec returns false.
    Thanks again in advance for your help. Have a great day.
    Regards,
    Rudi

    retcode=`echo $?`is a bit convoluted. Just use:
    retcode=$?I see no EOF line terminating your input. Your flavour of Unix might not like that - it might ignore the command, though I'd be surprised (AIX doesn't).
    replace the EXEC line with :
    select 'hello' from dual;
    and see if you get some output - then you know if sqlplus commands are being called from your script. You didn't mentioned whether you see the banner for sqlplus. Copy/paste the output that you get, it will give us much more of an idea.

Maybe you are looking for