Hive
  1. Hive
  2. HIVE-3386

Document how to import NULL values into a table at LanguageManual+Types (\N with Lazy SerDe)

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.9.0
    • Fix Version/s: None
    • Component/s: Documentation
    • Labels:
      None

      Description

      The documentation at https://cwiki.apache.org/confluence/display/Hive/LanguageManual+Types should be enhanced as follows:

      Handling of NULL values

      Missing values are represented by the special value NULL. To import data with NULL fields, check documentation of the SerDe used by the table. (The default Text Format uses LazySimpleSerDe which interprets the string \N as NULL when importing.)

      Reason:
      It's nearly impossible to find out how to make e.g. a string field to be NULL in hive without lot of googling. This is an important thing and should be documented properly at a clearly visible place (the Data Types page seems to be the most logical place to me though LanguageManual+DML would certainly also be a good place).

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Resolved Resolved
        6d 9h 18m 1 lefty@hortonworks.com 22/Aug/12 01:20
        Lefty Leverenz made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Hide
        Lefty Leverenz added a comment -

        Changed in the wikidoc.

        Show
        Lefty Leverenz added a comment - Changed in the wikidoc.
        Hide
        Lefty Leverenz added a comment -

        I added the new section verbatim to Data Types in the wiki but wonder why you used initial capitals for Text Format.

        Does this information also belong in "Inserting data into Hive Tables from queries" in DML as another bullet item in the Notes? Or should a note just refer to the Types doc "for information about types and NULL values"?

        Does the information also belong in the DDL docs? Wikidoc DDL already points to Types from its "Create Table" section, but in the Hive xdocs there's another DDL doc (misnamed DML) that could include this information in its "Using SerDes" section or just point to the Types wikidoc.

        Show
        Lefty Leverenz added a comment - I added the new section verbatim to Data Types in the wiki but wonder why you used initial capitals for Text Format. Does this information also belong in "Inserting data into Hive Tables from queries" in DML as another bullet item in the Notes? Or should a note just refer to the Types doc "for information about types and NULL values"? Does the information also belong in the DDL docs? Wikidoc DDL already points to Types from its "Create Table" section, but in the Hive xdocs there's another DDL doc (misnamed DML ) that could include this information in its "Using SerDes" section or just point to the Types wikidoc.
        Lefty Leverenz made changes -
        Field Original Value New Value
        Assignee Lefty Leverenz [ lefty@hortonworks.com ]
        Jakub Holy created issue -

          People

          • Assignee:
            Lefty Leverenz
            Reporter:
            Jakub Holy
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development