Return-Path: X-Original-To: apmail-datafu-dev-archive@minotaur.apache.org Delivered-To: apmail-datafu-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7D69117539 for ; Tue, 28 Oct 2014 19:31:28 +0000 (UTC) Received: (qmail 24337 invoked by uid 500); 28 Oct 2014 19:31:28 -0000 Delivered-To: apmail-datafu-dev-archive@datafu.apache.org Received: (qmail 24298 invoked by uid 500); 28 Oct 2014 19:31:28 -0000 Mailing-List: contact dev-help@datafu.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@datafu.incubator.apache.org Delivered-To: mailing list dev@datafu.incubator.apache.org Received: (qmail 24287 invoked by uid 99); 28 Oct 2014 19:31:28 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Oct 2014 19:31:28 +0000 X-ASF-Spam-Status: No, hits=-2000.6 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO mail.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with SMTP; Tue, 28 Oct 2014 19:31:06 +0000 Received: (qmail 10621 invoked by uid 99); 28 Oct 2014 19:28:34 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Oct 2014 19:28:34 +0000 Date: Tue, 28 Oct 2014 19:28:34 +0000 (UTC) From: "Russell Jurney (JIRA)" To: dev@datafu.incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (DATAFU-69) Create SelectFieldByName UDF - which, given a field who's value contains a field name, and *, returns the value of the field referenced by the field name MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DATAFU-69?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Russell Jurney updated DATAFU-69: --------------------------------- Attachment: DATAFU-69.patch Latest patch with name changed to SelectStringFieldByName > Create SelectFieldByName UDF - which, given a field who's value contains a field name, and *, returns the value of the field referenced by the field name > --------------------------------------------------------------------------------------------------------------------------------------------------------- > > Key: DATAFU-69 > URL: https://issues.apache.org/jira/browse/DATAFU-69 > Project: DataFu > Issue Type: Bug > Affects Versions: 1.3.0 > Reporter: Russell Jurney > Labels: features > Attachments: DATAFU-69.patch, DATAFU-69.patch, DATAFU-69.patch > > > define SelectFieldByName datafu.pig.util.SelectFieldByName(); > data = LOAD 'input' using PigStorage(',') AS (fieldName:chararray, text1:chararray, text2:chararray, text3:chararray); > data2 = FOREACH data GENERATE fieldName, SelectFieldByName(fieldName,*) as result; > data3 = FOREACH data2 GENERATE fieldName, result; > STORE data3 INTO 'output'; -- This message was sent by Atlassian JIRA (v6.3.4#6332)