Uploaded image for project: 'Pig'
  1. Pig
  2. PIG-3078

Make a UDF that, given a string, returns just the columns prefixed by that string

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.12.0
    • None
    • None

    Description

      This comes up fairly often, usually as the result of a join. Given that the resulting schema has the column name prepended, a udf in the following form could give just the columns from the desired relation:

      Pluck('relation_name', *)

      Attachments

        1. PIG-3078-0.patch
          6 kB
          Jonathan Coveney
        2. PIG-3078-1.patch
          6 kB
          Jonathan Coveney

        Issue Links

          Activity

            People

              jcoveney Jonathan Coveney
              jcoveney Jonathan Coveney
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: