<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Apache PIG - Guarantee that all the value in a column are Numeric Values in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152799#M36136</link>
    <description>&lt;P&gt;You can apply a filter or bincond operator on any column(s) of your relation X. You can get more details on available operators &lt;A target="_blank" href="https://pig.apache.org/docs/r0.7.0/piglatin_ref2.html#Arithmetic+Operators+and+More"&gt;here&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 28 Jul 2016 20:26:03 GMT</pubDate>
    <dc:creator>arunak</dc:creator>
    <dc:date>2016-07-28T20:26:03Z</dc:date>
    <item>
      <title>Apache PIG - Guarantee that all the value in a column are Numeric Values</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152796#M36133</link>
      <description>&lt;P&gt;Hi experts,

I've a dataset with 4 columns and want to know if the column B only have numbers, if the job detect some non numeric value I want to put that value into null.

Could I do this in PIG or must be Python embed pig?

Many thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 27 Jul 2016 23:35:37 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152796#M36133</guid>
      <dc:creator>m2014227</dc:creator>
      <dc:date>2016-07-27T23:35:37Z</dc:date>
    </item>
    <item>
      <title>Re: Apache PIG - Guarantee that all the value in a column are Numeric Values</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152797#M36134</link>
      <description>&lt;P&gt;You can use &lt;STRONG&gt;org.apache.pig.piggybank.evaluation.IsNumeric&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Some thing like 

&lt;/P&gt;&lt;PRE&gt;X = foreach Y generate ((org.apache.pig.piggybank.evaluation.IsNumeric($1)==true)?(int)$1:null)&lt;/PRE&gt;I have applied generate for one column, you can add rest of columns</description>
      <pubDate>Thu, 28 Jul 2016 02:13:35 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152797#M36134</guid>
      <dc:creator>arunak</dc:creator>
      <dc:date>2016-07-28T02:13:35Z</dc:date>
    </item>
    <item>
      <title>Re: Apache PIG - Guarantee that all the value in a column are Numeric Values</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152798#M36135</link>
      <description>&lt;P&gt;Brilliant &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; Only one more question: How can I add a Case Statement (or a If) to my X var;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Jul 2016 05:13:53 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152798#M36135</guid>
      <dc:creator>m2014227</dc:creator>
      <dc:date>2016-07-28T05:13:53Z</dc:date>
    </item>
    <item>
      <title>Re: Apache PIG - Guarantee that all the value in a column are Numeric Values</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152799#M36136</link>
      <description>&lt;P&gt;You can apply a filter or bincond operator on any column(s) of your relation X. You can get more details on available operators &lt;A target="_blank" href="https://pig.apache.org/docs/r0.7.0/piglatin_ref2.html#Arithmetic+Operators+and+More"&gt;here&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Jul 2016 20:26:03 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Apache-PIG-Guarantee-that-all-the-value-in-a-column-are/m-p/152799#M36136</guid>
      <dc:creator>arunak</dc:creator>
      <dc:date>2016-07-28T20:26:03Z</dc:date>
    </item>
  </channel>
</rss>

