How HANA handle NULL values

Hi frzz,
Can any one explain me how exactly HANA handles NULL values??
Best Regards,
Krishna.

Hi Krishna,
You can use IFNULL for the SQL queries/script instead of ISNULL . Since ISNULL is binary function and will be mostly used for the CE Functions based Calc views.
Try using the same queries with IFNULL instead of ISNULL, it should work
Best Regards
Rahul Jha

Similar Messages

  • How to handle Null value in Database Adapter

    I configured the DA Adapter, with operation type as "Perform an Operation on a Table - Select" and added few where clause parameters (StreetNo, StreetName city, country, state, zipcode)too.
    If we won't enter any value for any of the column in the table (S_ADDR_PER) is taking as NULL, so what happening is, if i give "%" or if i leave as "blank" to those columns(input for where clause parameter). The DB adapter not fetching any records. Any help to handle this situation.
    I need query like this...
    select * from S_ADDR_PER where city like '%' AND state is NULL AND addr_line_2 like '%';
    seems.... I can't use the pure SQL option since i don't know which column will be null. Some case the addr_line_2 column will be NULL in table, in some other case the state or city column will be null.

    Hi,
    you can handle null with date like this , If it doesn't wortk for you then please explain your problem.
    select NVL(to_char(sysdate,'DD-MON-YY'),'Not Recorded')
    from dual
    NVL(TO_CHAR(
    08-NOV-05
    select NVL(to_char(NULL,'DD-MON-YY'),'Not Recorded')
    from dual
    SQL> /
    NVL(TO_CHAR(
    Not Recorded
    Regards

  • Oracle Discoverer: How to handle null value

    In Oracle Discoverer, I pull data from a folder. When I hit Null value for a column, I want to replace it with data from another folders column. Something like the functionality of "nvl" of a SQL statement. How can I do the following query in Discoveror :
    example: select nvl(table1.column1,table2.column2) from table1, table2
    where table1.column7 = table2.column7.

    Hi,
    You first need to include any column from folder table2 into your report so that Discoverer will do the join. (This assumes the join between table1 and table2 is set up in your EUL). Then you can create a calculation containing nvl(table1.column1,table2.column2) . You can then remove the column from folder table2 and the join will stay in your workbook.
    Hope that helps,
    Rod West

  • Oracle Discoveror: How to handle null value

    In Oracle Discoveror, I pull data from a folder. When I hit Null value for a column, I want to replace it with data from another folders column. Something like the functionality of "nvl" of a SQL statement. How can I do the following query in Discoveror :
    example: select nvl(table1.column1,table2.column2) from table1, table2
    where table1.column7 = table2.column7.

    Hi,
    You first need to include any column from folder table2 into your report so that Discoverer will do the join. (This assumes the join between table1 and table2 is set up in your EUL). Then you can create a calculation containing nvl(table1.column1,table2.column2) . You can then remove the column from folder table2 and the join will stay in your workbook.
    Hope that helps,
    Rod West

  • How to handle null values in RTF templates

    Hi - I have two groups in a report for different SQL and two formulas for each group, CF_ELE_CNT and CF_ELE_CNT1. In the template I use the below code to print or not print a section.
    <?if:number(CF_ELE_CNT +CF_ELE_CNT1) >0?>    
    The problem is when there is no data in the second group its not creating the XML tag for CF_ELE_CNT1, though CF_ELE_CNT has 13, it still does not print that partucular section. If I remove CF_ELE_CNT1 from the condition it works fine. I was wondering how to handle this.
    Any help would be appreciated!!
    Thanks,
    Rav

    Hey Rav,
    You can add a check to identify it the element/tag is present or not
    <?if:(CF_ELE_CNT1)?> will give true, if the element is present otherwise falsesince you are adding the two elements, you have to add a or condition.
    <?if:(CF_ELE_CNT and number(CF_ELE_CNT) >0 ) or ( CF_ELE_CNT1 and CF_ELE_CNT1 >0)?>

  • How to delete null values in a table

    hi all,
    tell me please any one how to delete null values in a table
    example:
    in emp table is there
    empno ename job mgr sal deptno
    7900 scott 7902 2000 10
    7499 clerk 7900 20
    7834 james manager 3000 30
    like this in the above emp table there are some null values are there
    so how to delete the null values in emp table
    thanks,
    regards.
    Edited by: user9195968 on Feb 25, 2010 6:30 AM

    not too sure what you mean, perhaps you could supply a table description and some sample data
    but, consider
    delete from table_1 where column_1 is null
    commit
    /

  • How to Replace Null Value as 0 in an OBIEE11g Pivot Table? it's working 10g

    Hi,
    How to Replace Null Value as 0 in an OBIEE11g Pivot Table? it's working in obiee10g version.
    We have tried below methods
    1) criteria tab and edit the ‘column properties’ associated with your fact measure. Choose the ‘Data Format’ tab, tick to override the default format and choose ‘Custom’.
    It seems that the syntax for this custom format is positive-value-mask (semi colon) negative-value-mask (semi colon) null-mask. So this means we have a few options.
    E.g. if you want zeros (0) instead of null then enter:
    #,##0;-#,##0;0
    2) in that formula columns we have put it below case condition also ,
    Measure Column: Nom_amt --> edit formulas
    CASE WHEN Nom_amt IS NULL THEN 0 ELSE Nom_amt END
    3) we have uncheked IS NULL check box in the admin tool also
    I tried above formats still it's not working for me..kindly help me on this..
    thanks to do the needfull
    Best Regards,
    R.Devarasu

    Hi,
    Null value in database displaying as 0 in report, I need to keep value as in database, and I have one calculated row which is based on null values should also null in report.
    but it showing 0 for null values also so, my calculated row showing wrong result.
    my report is like
    col1 col2
    ABC 0
    BCD 12
    DEF -12 --this is calculated row.
    I require result like:
    col1 col2
    ABC null
    BCD 12
    DEF null --this is calculated row.
    Please let me know how I can achieve this.
    Thanks,
    Rahul

  • How to Replace Null Value as 0 in an OBIEE11g Pivot Table?

    Hi,
    How to Replace Null Value as 0 in an OBIEE11g Pivot Table? it's working in obiee10g version.
    We have tried below methods
    1) criteria tab and edit the ‘column properties’ associated with your fact measure. Choose the ‘Data Format’ tab, tick to override the default format and choose ‘Custom’.
    It seems that the syntax for this custom format is positive-value-mask (semi colon) negative-value-mask (semi colon) null-mask. So this means we have a few options.
    E.g. if you want zeros (0) instead of null then enter:
    #,##0;-#,##0;0
    2) in that formula columns we have put it below case condition also ,
    Measure Column: Nom_amt --> edit formulas
    CASE WHEN Nom_amt IS NULL THEN 0 ELSE Nom_amt END
    3) we have uncheked IS NULL check box in the admin tool also
    I tried above formats still it's not working for me..kindly help me on this..
    thanks in advance...
    Best Regards,
    R.Devarasu

    Hi Amith,
    I have update your suggested one,but it's working few of the rows only..remainings rows some of cells still NULL only
    Measure colmns is : Nom_SGD
    IFNULL(Nom_SGD,0.00)
    Movment : dynamic date calc by using $2-$1 oracle formula's
    Actually i am doing below things only,
    31/12/2011 31/03/2011 Movment
    Country
    India 100 -50 -150
    Singapore 200 200
    UK 1200 -1200
    USA 0.00 0.00 0.00 (here changed null as 0)
    Helpmeon this...

  • How to assign NULL value to an ITEM in Forms Personalization?

    Hi,
    how to assign NULL value to an ITEM in Forms Personalization?
    please suggest me.
    Thanks

    I don't know what your form personalization does and maybe I misunderstand you ...
    Try
    :item_name := null;

  • Model of how APEX handles data (values)?

    Reference {thread:id=2486655}
    I'm trying to get a model of how APEX handles data (values). There are several places(?) that data (values) can exist. Or so it seems. I'm trying to understand how these work -- to put all the pieces together.
    Question:
    A) Where data can be?
    1) In the database
    2) In the session
    3) Rendered -- and hence displayed on the screen, if a displayed value -- but not in the session
    4) In perhaps(?) some working memory pool(?) but different from the page rendered values I see on the screen?
    5) Other?
    Why do I think this is relevant?
    Question:
    B) If there are rendered values and session values different from the rendered values, then when code executes, which of these values (rendered or session) is it executing against?
    And maybe the answer is, "You don't understand what's going on." Yes, "Exactly!" Hence the question.
    Best wishes,
    Howard

    Howard (DBA in Training) wrote:
    I'm putting this together now. For example:
    I set the value of a Page Item (say, :P2_DATA) to "BEFORE" in a Before Region process and change it to "AFTER" in an After Region Process. 'BEFORE' was displayed on the screen but 'AFTER' was in the session state. So I see that PL/SQL changes these values in the session state. But it doesn't "go back" to change the HTML after the region has been rendered -- hence we see BEFORE shown on the screen. (I'll have to think about what a Dynamic Action does.)
    Also, if a page item has a default value, say 'DEFAULT' then that value doesn't get into the session state. At least, not with my current settings. Oh, that explains a lot of confusion!! I suppose there's a logical reason for this but who would expect default values to be differently from other PL/SQL operations on the item?
    Questions:
    1) So why does a default value not get put into the session state?Several reasons, among them:
    *1. When/why is the value required?* Region items (and thus their source and default values) are rendered in region/item sequence order. The item's source/default value would therefore not be available in session state until it's rendering point. This is frequently later in page show processing than the value is actually required, such as the common use case of including a data value in the page or region title. Setting the value in a Before Header/Regions computation or process makes it available as required before the item is actually rendered.
    *2. The rendered page might not be submitted.* Default values are typically set when a page will create a new row. Consider the situation where the user clicks a "Create" button and is presented with an order entry form containing several default values. They then decide they don't want to create a new order after all, and navigate away from the form page via some mechanism that uses a redirect rather than a submit (such as a default "Cancel" button). This means that no page submit processing is performed, and generally that no session state management is performed. If the default values were set in session state, the order entry page would contain the default values for the non-existent order despite the user never submitting it. This may have unwanted side-effects if these values are referenced elsewhere in the application, and therefore would require extra session state management to be built into the application.
    *3. A rendered item might not be submitted with the page.* Per the HTML specification, the values of disabled controls unchecked checkboxes are not POSTed on page submit. Consider a situation where a checkbox item is set with several default values, but the application requires that the checkboxes be cleared and disabled by a dynamic action if the user chooses certain options from a select list. In this case, on page submission no values are submitted into session state for the checkbox item. If the defaults had been set in session state, then the application would be in an inconsistent state, with the user-selected option indicating that none of the checkboxes were checked, but with session state holding values showing that they were. This would require additional processing to ensure that the application's state was consistent before saving it to the database.<sup>1</sup>
    2 & 3 are particularly significant in basic wizard-generated applications. Doing things in this way, the wizard-generated DML and navigation "just works", without the need for additional session state management.
    2) Is there a Page Item setting that causes the default value to be saved to the session state?No. Hopefully the explanations above provide sufficient reason to show why this is genearlly not desirable. On the rare occasions when it is required, set the session state value using a computation or process.
    <sup>1</sup> There are other reasons&mdash;mainly security related&mdash;that make it good practice to perform such checks in more complex and internet-facing applications anyway.

  • How to handle null pointer exception

    dEAR ALL
    how to handle null pointer exception
    public void xxperscompmatchcase(OAPageContext pageContext,
    OAWebBean webBean,String cid,String pid)
    xxcrmleadperslastnameVOImpl vo=getxxcrmleadperslastnameVO();
    xxcrmleadcompnameVOImpl vo1=getxxcrmleadcompnameVO();
    vo.setWhereClauseParams(null);
    vo1.setWhereClauseParams(null);
    vo.setWhereClauseParam(0,pid);
    vo1.setWhereClauseParam(0,cid);
    vo.executeQuery();
    vo1.executeQuery();
    String compname="";
    String plname="";
    if(vo1.first().getAttribute("CompName")!=null)
    compname=(String)vo1.first().getAttribute("CompName");
    else
    compname="";
    if((String)vo.first().getAttribute("PersLastname")!=null)
    plname=(String)(String)vo.first().getAttribute("PersLastname");
    else
    plname="";
    OAFormattedTextBean p =
    (OAFormattedTextBean)webBean.findChildRecursive("personmatchcase");
    OAFormattedTextBean b =
    (OAFormattedTextBean)webBean.findChildRecursive("matchcase");
    b.setValue(pageContext,
    "The Lead is matched to company " + compname.toUpperCase());
    p.setValue(pageContext,
    "The Lead is matched to person " + plname.toUpperCase());
    it is going to null pointer exception
    how to handle this exception

    Hi,
    try
    //Write your logic here, which can generate any exception
    catch(Exception e)
    //Write your exception specific code here
    Regards,
    Reetesh Sharma

  • Handling null value in where condition

    CREATE OR REPLACE package body GetRefCursors is
    function sfGetAccountInterval
    ( pFirstAccount in ACCOUNTS.ACCOUNT_NO%type
    ,pLastAccount in ACCOUNTS.ACCOUNT_NO%type)
    return csGetResultSet is
    csGetAccounts csGetResultSet;
    begin
    open csGetAccounts for
    SELECT accounts.account_no,accounts.name
    FROM accounts
    WHERE accounts.account_no BETWEEN pFirstAccount AND pLastAccount
    ORDER BY accounts.account_no;
    return csGetAccounts;
    end sfGetAccountInterval;
    end GetRefCursors;
    how can i handle the condition if pFirstAccount parameter having null value?
    do i need to use Dynamic SQL here?

    no need for dynamic stuff.
    You could use the NVL function, but it depends what you want... If you want NULL to be considered the lowest possible account number, then you could do something like
    nvl (pFirstAccount, 0)where the zero is the lowest possible number.

  • Using Convert to handle NULL values for empty Strings ""

    After having had the problem with null values not being returned as nulls and reading some suggestion solution I added a converter to my application.
      <converter>
        <converter-id>NullStringConverter</converter-id>
        <converter-for-class>java.lang.String</converter-for-class>
        <converter-class>com.j2anywhere.addressbookserver.web.NullStringConverter</converter-class>
      </converter>
    ...I then implemented it as follows:
      public String getAsString(FacesContext context, UIComponent component, Object object)
        System.out.println("Converting to String : "+object);
        if (object == null)
          System.out.println("READING null");
          return "NULL";
        else
          if (((String)object).equals(""))
            System.out.println("READING null (Second Check)");
            return null;       
          else
            return object.toString();
      public Object getAsObject(FacesContext context, UIComponent component, String value)
        System.out.println("Converting to Object: "+value+"-"+value.trim().length());
        if (value.trim().length()==0 || value.equals("NULL"))
          System.out.println("WRITING null");
          return null;
        else
          return value.toUpperCase();
    ...I can see that it is converting my values, however the object to which the inputText fields are bound are still set to empty strings ""
    <h:inputText size="50" value="#{addressBookController.contactDetails.information}" converter="NullStringConverter"/>Also when reading the object values any nulls are already converted to empty strings before ariving at the converter. It seems that there is a default converter handling string values.
    How can I resolve this problem as set nulls when the input value is an empty string other then checking every string in my class individually. I would really hate to pollute my object model with empty string tests.
    Thanks in advance
    Edited by: j2anywhere.com on Oct 19, 2008 9:06 AM

    I changed my converter as suggested :
      public Object getAsObject(FacesContext context, UIComponent component, String value)
        if (value == null || value.trim().length() == 0)
          if (component instanceof EditableValueHolder)
            System.out.println("SUBMITTED VALUE SET TO NULL");
            ((EditableValueHolder) component).setSubmittedValue(null);
          else
            System.out.println("COMPONENT :"+component.getClass().getName());
          System.out.println("Converting to Object: " + value + "< to " + null);
          return null;
        System.out.println("Converting to Object: " + value + "< to " + value);
        return value;
      }which produces the following output :
    SUBMITTED VALUE SET TO NULL
    Converting to Object: < to null
    Info : The INFO line however comes from my controller object where I print out the set value :
    package com.simple;
    import java.util.ArrayList;
    import java.util.List;
    public class Controller
      private String information;
      /** Creates a new instance of Controller */
      public Controller()
        System.out.println("Createing Controller");
        information = "Constructed";
      public String process()
        System.out.println("Info : "+getInformation());
        return "processed";
      public String reset()
        setInformation("Re-Constructed");
        System.out.println("Info : "+getInformation());
        return "processed";
      public String setNull()
        setInformation(null);
        System.out.println("Info : "+getInformation());
        return "processed";
      public String getInformation()
        return information;
      public void setInformation(String information)
        this.information = information;
    }I also changes my JSP / JSF page a little. Here is the updated version
    <%@page contentType="text/html"%>
    <%@page pageEncoding="UTF-8"%>
    <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
    <%@taglib prefix="f" uri="http://java.sun.com/jsf/core"%>
    <%@taglib prefix="h" uri="http://java.sun.com/jsf/html"%>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <%--
        This file is an entry point for JavaServer Faces application.
    --%>
    <html>
      <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
      </head>
      <body>
        <f:view>
          <h:form>
            <h:inputText id="value" value="#{Controller.information}"/>
            <hr/>
            <h:commandLink action="#{Controller.process}">
              <h:outputText id="clicker" value="Process"/>
            </h:commandLink>             
            <hr/>
            <h:commandLink action="#{Controller.reset}">
              <h:outputText id="reset" value="Reset"/>
            </h:commandLink>             
            <hr/>
            <h:commandLink action="#{Controller.setNull}">
              <h:outputText id="setNull" value="Set Null"/>
            </h:commandLink>             
          </h:form>
        </f:view>
      </body>
    </html>The converter is declared for the String class in the faces configuration file. From the log message is appears to be invoked, however the object is not set to null.
    I tested this with JSF 1.2_04-b20-p03 as well as 1.2_09-b02-FCS.
    any other suggestions what could be causing this.

  • How to post null values from h:inputText?

    Hello,
    I have a form made of h:inputText fields that map to an entity class as the backing bean. Whenever I post the form from a web page, all the fields that I did not fill out and that are mapped to String fields in the entity class are set to "" (empty string) instead of null.
    However, I would like to post null values to my entity, because that would indicate that the user did not fill out the field. In other contexts (outside of the web app) it is possible to set the fields to empty strings, but from the web app it should always be null. How can I get JSF to do this correctly?
    Also, when reading entitys with null values from the database, these are converted to empty h:inputText fields, so this direction works as expected.
    Ulrich

    I haven't seen a solution for this as far.
    This is how I do it:
    public void action() {
        if (isEmpty(inputValue)) {
            // do your thing
        } else {
            // do your thing
    public static boolean isEmpty(Object value) {
        if (value == null) {
            return true;
        if (value instanceof String && ((String) value).trim().length() == 0) {
            return true;
        if (value instanceof Collection && ((Collection) value).size() == 0) {
            return true;
        // And go so on .. make it an utility method.
        return false;
    }

  • How to replace NULL values from main table

    Dear all,
    I like to remove the NULL values from a main table field. Or the question is how to replace any part of the string field in MDM repository main table field.
    e.g.   I have a middle name field partly the value is NULL in some hundreds of records, I like to replace NULL values with Space
    any recommendation.
    Regards,
    Naeem

    Hi Naeem,
    You can try using Workflows for automatically replacing NULLs with any specific value.
    What you can do is: Create a workflow and set trigger action as Record Import, Record Create and Record Update. So, that whenever any change will occur in the repository; that workflow will trigger.
    Now create an assignment expression for replacing NULLs with any specific value and use that assignment expression in your workflow by using Assign Step in workflow.
    For exiting records, you will have to replace NULLs manually using the process given by Preethi else you can export those records in an Excel spreadsheet which have NULLs and then replace all NULLs with any string value and then reimport those records in your MDM repository.
    Hope this will solve your problem.
    Regards,
    Varun
    Edited by: Varun Agarwal on Dec 2, 2008 3:12 PM

Maybe you are looking for

  • Org.apache.xerces.parsers.SAXParser class, where do I find it?

    I don´t know if this is the right place to ask, but maybe someone will know: I need the class org.apache.xerces.parsers.SAXParser that should be included in the Apache Xerces project. Here is the API: [http://xerces.apache.org/xerces2-j/javadocs/xerc

  • What does the sync choice "erase data before syncing" do?

    I want to synce a Sony Ericsson cell with my ical via isync. One of the choices before syncing asks whether I want to erase info on the cell before syncing or merge the info on the cell with the mac. I only want to sync the calendar data and not the

  • TS1424 cannot download an app not enough storage?

    paid for The  Brian Cox wonders of the solar system and keep getting a message telling me i  do not have enough storage space so spent an extra £ 28 on extra cloud and still cannot download   any ideas????

  • Script font increased automatically

    Hi All, We are using a custom Script and we have given the Font size as 32 (Helve), it was working till 15th of the month but from 16th it is showing in big font size suddently. There were no changed done to the Script. kIndly let us know where would

  • In warehouse how to configure the WAM

    hi in warehouse how to configure the wam how to define the variant can hoe to see the trafic lights convert from red to green.