Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-138

Provide option to export a HEADER

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 0.7.0
    • Clients, Query Processor
    • None

    Description

      When writing data to directories or files for later analysis, or when exploring data in the hive CLI with raw SELECT statements, it'd be great if we could get a "header" or something so we know which columns our output comes from. Any chance this is easy to add? Just print the column names (or formula used to generate them) in the first row?

      SELECT foo.* WITH HEADER FROM some_table foo limit 3;

      col1 col2 col3
      1 9 6
      7 5 0
      7 5 3

      SELECT f.col1-f.col2, col3 WITH HEADER FROM some_table foo limit 3;

      f.col1-f.col2 col3
      -8 6
      2 0
      2 3

      ...etc

      Attachments

        1. HIVE-138.patch
          6 kB
          Paul Butler

        Issue Links

          Activity

            People

              paulbutler Paul Butler
              akramer Adam Kramer
              Votes:
              5 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: