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

indexof / lastindexof / lower / replace / substring udf's

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Trivial
    • Resolution: Fixed
    • None
    • 0.4.0
    • None
    • None
    • Patch Available

    Description

      We parse some apache logs using pig and are using some pretty simple udf's like this:

      B = FOREACH A GENERATE substring(uri, lastindexof(uri, '/')+1, indexof(uri, '.txt')) as lang;

      It's pretty simple stuff but I figured someone else might find it useful.

      Attachments

        1. addSomeUDFsPatch.patch
          18 kB
          Bennie Schut
        2. dateExtractorPatch.patch
          1 kB
          Bennie Schut

        Activity

          People

            bennies Bennie Schut
            bennies Bennie Schut
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: