Select_list_from_lov_xl and nulls

I am creating a column on a report which will have an lov using the code below:-
apex_item.select_list_from_lov_xl(p_idx,
p_value,
'ARL LOV',
l_attributes,
'YES',
'%null%',
'Please Select',
NVL(p_item_id,item_id(p_idx,p_rownum)));
The problem I have is that for exisiting records where the value of the column (that the lov is for) is null it is not translating the null into the text 'Please Select'. The text is displayed in the lov when you click on the list but it should be displayed as default, as it is for page items that use the same lov.
Has anyone else seen this happening and do you know how I can get around it?
Andy.

Thanks Daniel for your reply.
I tried what you suggested, my lov query is
Select 'Please Select' show, null value
from dual
union all
SELECT arle_description||' - '||arle_code show , arle_code value
FROM assessment_risk_levels
WHERE arle_current_ind = 'Y'
ORDER BY 1
I called select_list_from_lov_xl with p_show_null = 'NO'
However I still cannot get 'Please Select' displayed automatically for rows where the value is null. A blank is displayed and 'Please Select' is displayed at the top of the LOV.
Any other ideas?

Similar Messages

  • Difference between Null and null?

    What is the difference between null and NULL?
    When is each used?
    Thanks,

    veryConfused wrote:
    There is a null in java, but no NULL. null means no value. However, when assigning value, the following is different:Although the empty String has no special role. Null means, the referential type is not assigned (doesn't refer) to a specific object. The empty String is just another object though, so seeing it or pointing it out as something special when it actually isn't at all (no more special than new Integer(0) or new Object[0]) just adds to the confusion.

  • How to differentiate the EMPTY Records and Null Values in DSO

    Hello....how is everyone here?? Ehehehe!
    I try to load some data from the flat file which contains some EMPTY data and Null Values for the records. The data type for the InfoObjects of the fields "Quantity" is "number". The sample data from the flat file (CSV) are as below:
    Food              Quantity
    Hamburger  -       12
    Cheese        -       0
    Vegetable      -               (Empty)
    When I try to load the above sample data to the DSO, I get the results of the data as follow:
    Food              Quantity
    Hamburger     - 12.000
    Cheese           -  0.000
    Vegetable         - 0.000
    In this case, how can the user differentiate whether the records is contain empty value of null values in DSO? This is kinda of hard to differentiate the both scenarios above. Is there any way to differentiate the scenarios described here?
    Thanks alot =)

    Hi Fluffy,
    It depends on the initial values of the data type
    The inital values For quantity/Currency/ Numbers it takes spaces as 0
    for char it is SPACE
    We cannot differeniate between space and null values.
    IF you have to force this then define quantity as char and load the data. we will not have units and aggregation in this case.
    Hope this helps.
    PV

  • How to force simple tags and null attributes to appear when using SQL/XML?

    Hello everybody:
    I'm developing a non-schema based XMLType view.
    When the XML document is generated, i noticed two things I need to manage in order to achieve the desired result:
    1. Oracle generates a <tag></tag> pair for each XMLELEMENT defined; in my case, some tags need to appear as <tag/>... how do I do? Is it possible when using schema based XMLType views? Is it possible while using a non-schema approach?
    2. When using XMLATTRIBUTE('' AS "attribute") or XMLATTRIBUTE(NULL AS "attribute"), no one attribute with label "attribute" and null value appears at the output; how do I force to Oracle DB to render those attributes which are with no values (needed to render those attributes as another parsing code will await for all the items)?
    3. Some tip about how to route the output to an XML text disk file will be appreciated.
    Thanks in advance.
    Edited by: Enyix on 26/02/2012 11:21 PM
    Edited by: Enyix on 26/02/2012 11:22 PM

    Hello odie_63, thanks for your reply:
    Reasons why needed single tags are these two next: Needed to generate a single XML file from 50,000,000 rows, where the XML ouput matches not only row data but another default values for another elements and attributes (not from database but using strings and types with default values); by using start and end tag, the generated file is as much twice bigger than using single tags; second, needed a very precise presentation for all the document.
    For generating that document, currently focus is based on using a batch process relying on Spring Batch with using a single JDBC query where a join happens between two tables. From my point of view, that approach uses: database resources, network resources, disk resources, and processing resources, including the price of making the join, sending to network, creating objects, validating, and making the file (Expending too much time generating that XML file). That processs currently is in development.
    I think possibly another approach is delegating the complete generation of that file to the database using its XML capabilities. My current approach following your recomendations is to generate a clob where I will put all the XML and putting it into a table. It leads me to another issues: Considering limitations on memory, processing and disk space, needed to append a single row-as-xml into the clob as soon as possible, and putting the clob inside the field as soon as possible, or putting the clob inside the field, and appending into it as the data is generated; so How do I manage the process in order to achieve that goals?. Seen these issues aren't related to my original question, so I'll open a new post. Any help will be apreciated.
    Thanks again in advance.

  • How to check empty string and null? Assign same value to multiple variables

    Hi,
    1.
    How do I check for empty string and null?
    in_value IN VARCHAR2
    2. Also how do I assign same value to multiple variables?
    var_one NUMBER := 0;
    var_two NUMBER := 0;
    var_one := var_two := 0; --- Gives an error
    Thanks

    MichaelS wrote:
    Not always: Beware of CHAR's:
    Bug 727361: ZERO-LENGTH STRING DOES NOT RETURN NULL WHEN USED WITH CHAR DATA TYPE IN PL/SQL:
    SQL> declare
      2    l_str1   char (10) := '';
      3    l_str2   char (10) := null;
      4  begin
      5  
      6    if l_str1 is null
      7    then
      8      dbms_output.put_line ('oh STR1 is null');
      9    elsif l_str1 is not null
    10    then
    11      dbms_output.put_line ('oh STR1 is NOT null');
    12    end if;
    13  
    14    if l_str2 is null
    15    then
    16      dbms_output.put_line ('oh STR2 is null');
    17    elsif l_str2 is not null
    18    then
    19      dbms_output.put_line ('oh STR2 is NOT null');
    20    end if;
    21  end;
    22  /
    oh STR1 is NOT null
    oh STR2 is null
    PL/SQL procedure successfully completed.
    SQL> alter session set events '10932 trace name context forever, level 16384';
    Session altered.
    SQL> declare
      2    l_str1   char (10) := '';
      3    l_str2   char (10) := null;
      4  begin
      5  
      6    if l_str1 is null
      7    then
      8      dbms_output.put_line ('oh STR1 is null');
      9    elsif l_str1 is not null
    10    then
    11      dbms_output.put_line ('oh STR1 is NOT null');
    12    end if;
    13  
    14    if l_str2 is null
    15    then
    16      dbms_output.put_line ('oh STR2 is null');
    17    elsif l_str2 is not null
    18    then
    19      dbms_output.put_line ('oh STR2 is NOT null');
    20    end if;
    21  end;
    22  /
    oh STR1 is null
    oh STR2 is null
    PL/SQL procedure successfully completed.
    SQL> SY.

  • Varchar2, empty strings and NULL

    Hi all,
    When inserting an empty string into a column of type varchar2 - is a NULL value stored in the column by the database? I've seen conflicting reports, and I know that the SQL 1992 spec specifies that empty strings not be treated as a NULL value, but that Oracle has traditionally treated zero length strings stored in a varchar2 column as NULL.
    So, is there a way to store an empty string in a varchar2 column as an empty string and not a NULL value?
    TIA,
    Seth

    It can be even more complicated or annoying than NULL not equal to ASCII NULL.
    example:
    create table test_null
    (fld1 varchar2(10),
    fld2 varchar2(10),
    fld3 varchar2(20));
    insert into test_null values (chr(0),null, 'chr(0) and null');
    insert into test_null values (null, null, 'null and null');
    insert into test_null values ('', chr(0), ''''' and chr(0)');
    insert into test_null values ('', null, ''''' and null');
    select * from test_null;
    FLD1       FLD2       FLD3
                          chr(0) and null
                          null and null
                          '' and chr(0)
                          '' and null
      1  DECLARE
      2  BEGIN
      3   for c1 in (select fld1, fld2, fld3 from test_null) loop
      4      if c1.fld1 = c1.fld2 then
      5         dbms_output.put_line(c1.fld3||' Are equal'||
      6                '  Length fld1 = '||to_char(length(c1.fld1))||
      7                ' Length fld2 = '||to_char(length(c1.fld2)));
      8      else
      9         dbms_output.put_line(c1.fld3||' Are NOT equal'||
    10                '  Length fld1 = '||to_char(length(c1.fld1))||
    11                ' Length fld2 = '||to_char(length(c1.fld2)));
    12      end if;
    13      dbms_output.put_line(' ');
    14   end loop;
    15*  END;
    SQL> /
    chr(0) and null Are NOT equal  Length fld1 = 1 Length fld2 =
    null and null Are NOT equal  Length fld1 =  Length fld2 =
    '' and chr(0) Are NOT equal  Length fld1 =  Length fld2 = 1
    '' and null Are NOT equal  Length fld1 =  Length fld2 =
    PL/SQL procedure successfully completed.

  • Difference between IS NULL and = NULL

    Hello Guys,
    In 10gR2 what is the difference between IS NULL and = NULL
    Thanks,
    Imran

    Just don't use the second, because the comparison operator = cannot deal with NULLs as you (probably) hope it can:
    SQL> create table t1 as select rownum as id, 'test' as word from dual connect by level<=2;
    Table created.
    SQL> update t1 set word=null where id=1;
    1 row updated.
    SQL> commit;
    Commit complete.
    SQL> select * from t1;
            ID WORD
             1
             2 test
    SQL> select * from t1 where word is null;
            ID WORD
             1
    SQL> select * from t1 where word = null;
    no rows selectedKind regards
    Uwe Hesse
    http://uhesse.wordpress.com

  • Difference between Null in c and Null in Oracle

    Hi,
    Can any one tell me the difference between NULL in C language and NULL in Oracle
    Rds,
    Naga

    > Null is some garvage value in oracle.
    Not sure what you mean.
    AFAIK and not being a C programmer myself, isn't null CHR(0) in C? I'm not sure the two concepts (SQL null and C null) have anything in common.

  • Difference between -1 and null in the targettype filed

    Hi
    Could anyone advise what is the difference between -1 and null in the targettype filed in marketing documents?
    For example, in Sales Quotation - Rows (QUT1) table, I found for some open sales quotations, the field is null however the DB help file suggest the default value is -1 so I suppose it should be -1 for open documents.
    Many thanks for your advisory.

    Hi, Qian!
    I investigated that "-1" value appears in targettype field in Sales Quotation Rows (QUT1 table) when you Dublicate a Sales Quotation document (Ctrl + D). And NULL value appears when you create a new document without dublicating.
    In case you want to equal these 2 "empty"-values using T-SQL, you can use ISNULL(targettype, -1) function - this will give you -1 for both the "empty"-values
    HTH!
    Message was edited by: Aleksey Kuznetsov

  • Difference between void and null?

    wht is da difference between void and null w.r.t java?

    corlettk wrote:
    Why do you care, unless you're implementing a java compiler or JVM?Wow, you sure do suck at helping out in a forum. Why even make this post? You're not helping the OP any, and you made yourself look like a tool.
    To the op:
    Null is java's version of a null value. Java's version is more strict then many other languages, and will not work in a boolean expression or anywhere code expects a real and not null value. It's simply null.
    Void is java's way of declaring no return type on a method. Methods that are void take no 'return' statement and if one is provided will cause a fatal error. The exception to this is using 'return' without a value, which returns control to the caller of the method.
    Observe:
    //this method returns an int
    public int return_int(){
        int value = 5;
        return value;
    //this method does not return an int
    public void return_nothing(){
        int another_value = 123;
        System.out.println("Here's the value: " + return_int());
    //this method does not return anything
    public void nothing_returned(){
        return_nothing();
        return;
        System.out.println("This line never gets printed; the method returned control already!");
    }

  • What is the difference between string != null and null !=string ?

    Hi,
    what is the difference between string != null and null != string ?
    which is the best option ?
    Thanks
    user8729783

    Like you've presented it, nothing.  There is no difference and neither is the "better option".

  • Difference between empty plsql record and null plsql record

    Hi there,
    I am kinda getting confused with empty plsql record and null plsql record.
    How do I assign plsql record to be empty and to be null?
    create type emp_obj as object (enum number, ename varchar2);
    CREATE OR REPLACE TYPE emp_type AS TABLE OF emp_obj;
    Thanks

    First of all, do not use term PL/SQL record in this context. Record type in PL/SQL is completely different from object type. Secondly, there are 2 states of a nested table:
    1. Unintialized:
    SQL> create or replace
      2    type emp_obj_type as object(enum number, ename varchar2(10));
      3  /
    Type created.
    SQL> create or replace
      2    type emp_tbl_type as table of emp_obj_type
      3  /
    Type created.
    SQL> declare
      2      v_emp_tbl emp_tbl_type;
      3  begin
      4      v_emp_tbl.extend;
      5  end;
      6  /
    declare
    ERROR at line 1:
    ORA-06531: Reference to uninitialized collection
    ORA-06512: at line 4
    SQL> 2 Empty:
    SQL> set serveroutput on
    SQL> declare
      2      v_emp_tbl emp_tbl_type := emp_tbl_type();
      3  begin
      4      dbms_output.put_line('Nested table v_emp_tbl has ' || v_emp_tbl.count || ' element(s).');
      5  end;
      6  /
    Nested table v_emp_tbl has 0 element(s).
    PL/SQL procedure successfully completed.
    SQL> NULL aplies to nested table element, not to nested table itself:
    SQL> declare
      2      v_emp_tbl emp_tbl_type := emp_tbl_type();
      3  begin
      4      v_emp_tbl.extend;
      5      if v_emp_tbl(1) is null
      6        then
      7          dbms_output.put_line('Nested table v_emp_tbl first element is NULL.');
      8      end if;
      9  end;
    10  /
    Nested table v_emp_tbl first element is NULL.
    PL/SQL procedure successfully completed.
    SQL> SY.

  • OBIEE 11g - zeros and nulls and rows, oh my!

    Hi, dumb question here, but I need some help with handling zeros and nulls with OBIEE.
    First off, I have a fact table that contains five "metrics" - A, B, C, D, and E. Often (but not always), only 1 of the 5 columns is populated, the others are NULL.
    In the RPD, I've brought in these 5 columns and set their aggregation to SUM. In addition, I've created other calculated metrics such as F = A+B, G = A+C+E, etc. To get these calculations to work right, I seem to have to use IfNull(metric,0) often, because apparently NULL plus a number equals NULL.
    From a usability standpoint, here's what I'm seeing on reports that I don't like (for instance, imagine the particular report is displaying columns A, B, and F only)
    #1 - If A and B are both NULL, the F column always shows as a 0 because the formula is IfNull(A,0) + IfNull(B,0). It would be nice if I could get F to also show NULL, without making the formula complicated
    #2 - Rows are showing on the report where everything on the row is either NULL or 0. I assume this is because one of the columns not being displayed has numbers in it. Is there a way to get OBIEE to not show rows that have all zeros or NULLs? Or is this due to the fact that the IfNull(A,0) + IfNull(B,0) is returning a non-NULL answer...and if I modified the formula so it did return a NULL it would magically go away?
    Thanks!
    Scott

    p.s. regarding issue #2...I suppose I could put a filter on to filter out rows with all zeros or NULLs, but this filter gets uglier and uglier as the number of columns grows...and I wouldn't want developers to have to do this.
    Thx,
    Scott

  • Reg: concept of COUNT and NULLs -

    Hi Experts,
    I have a simple conceptual doubt regarding COUNT and NULLs.
    Even I have experimented and can justify the behaviour, just need to confirm once with guru's and experts over here.
    Workout:
    CREATE TABLE test_x1
    AS
    SELECT 1 col1, 'a' col2, 'a1' col3 FROM dual UNION ALL
    SELECT 2 col1, 'a' col2, 'a1' col3 FROM dual UNION ALL
    SELECT 3 col1, 'a' col2, 'a1' col3 FROM dual UNION ALL
    SELECT 4 col1, 'a' col2, 'a1' col3 FROM dual UNION ALL
    SELECT 5 col1, 'a' col2, 'a1' col3 FROM dual UNION ALL
    SELECT 6 col1, 'a' col2, NULL col3 FROM dual UNION ALL
    SELECT NULL col1, NULL col2, NULL col3 FROM dual UNION ALL
    SELECT 8 col1, 'a' col2, NULL col3 FROM dual;
    SELECT
      Count(*),
      Count(col1),
      Count(col2),
      Count(col3)
    FROM test_x1;
    COUNT(*) COUNT(COL1) COUNT(COL2) COUNT(COL3)
           8           7           7           5
    My justification:
    COUNT(*) - It counts for physical *rowid* ,and doesn't bother to check if data in the columns is it NULL or anything else.
    Whereas, COUNT(<column>) - just scans/counts the known values and NOT NULLs.
    Is the above correct? Please advise me on this.
    -- Ranit

    it's documented: http://docs.oracle.com/cd/E11882_01/server.112/e41084/functions039.htm#SQLRF00624
    If you specify expr, then COUNT returns the number of rows where expr is not null. You can count either all rows, or only distinct values of expr.
    If you specify the asterisk (*), then this function returns all rows, including duplicates and nulls. COUNT never returns null.
    So the answer is: yes.

  • VALIDATE_LAYER_WITH_CONTEXT - Rowid and NULL in result table

    Hello,
    Oracle 10g R2
    I performed validity test using VALIDATE_LAYER_WITH_CONTEXT as follow:
    CREATE TABLE RESULT_TABLE_CP(SDO_ROWID ROWID, RESULT VARCHAR2(2000));
    CALL SDO_GEOM.VALIDATE_LAYER_WITH_CONTEXT('VESSEL_ZONE_GEOMETRY', 'POLYGON', 'RESULT_TABLE_CP');
    What puzzled me was the result table contained the rowid and NULL as the result for each geometry. I was expecting to see what the error is, not just NULL.
    However when I use VALIDATE_GEOMETRY_WITH_CONTEXT to test the same layer, I got TRUE for all of them, as:
    select DISTINCT SDO_GEOM.VALIDATE_GEOMETRY_WITH_CONTEXT(a.POLYGON,b.DIMINFO)
    from VESSEL_ZONE_GEOMETRY a,
    USER_SDO_GEOM_METADATA b
    where b.TABLE_NAME = 'VESSEL_ZONE_GEOMETRY'
    and b.COLUMN_NAME = 'POLYGON'
    and a.POLYGON is not null;
    SDO_GEOM.VALIDATE_GEOMETRY_WITH_CONTEXT(A.POLYGON,B.DIMINFO) ------------------------------------------------------------------------------------
    TRUE
    Any suggestion would be much appreciated!
    Thanks, CP

    Can you get the geometry by running
    select polygon from VESSEL_ZONE_GEOMETRY where rowid = '....';

Maybe you are looking for

  • Mac Mini and Bluetooth Recent Problems (Mighty Mouse, Wireless Keyboard)

    Hello there, I have an issue with my Mac Mini. We had a storm here recently, so I switched my Mac off. After that, I turned it on, but to my surprise my Wireless Mighty Mouse and Wireless Keybord do not function any more. The green dot under the mous

  • Portlet caching in weblogic portal 10.3

    Hi, I implemented the following for testing portlet caching. 1) I have one JSR/168 portlet with cache enabled(Render Cacheable property set to true). This portlet displays time. 2) Have another JSP portlet which prints the cache names and size of the

  • Cloning question

    Hi All, I have a question about cloning. In copying apps tier to destination, I am asked to copy those files to appldev, and not applmgr. The database files are still under oracle. I am not sure what will be the impact from this? Any process or scrip

  • Keytool seems to generate private key outside of HSM

    I am investigating integration with LunaSA (Safenet HSM) and JDK. LunaSA rejects key generation through JDK PKCS#11 wrapper. When I execute "keytool" command, then, PKCS#11 wrapper seems to generate private key outside of the HSM. Actually, the PKCS#

  • Itunes says "your request is temporarily unavailable to be processed, please try again later" what do i do??

    i try to go to purchase history in iTunes and it says "your request is temporarily unavailable to be processed, please try again later" i have tried again later and i have the latest update for iTunes, please help