title: Perform SUBSTRING on a Pig Latin Command Parameter
body: <p>I have a pig script that is passed a command argument as part of oozie workflow, I want to create a new variable as a substring of the passed parameter.
  eg:</p>
  
  <pre><code>%declare VAR1 SUBSTRING($INPUT, 0, 5);
  </code></pre>
  
  <p>The error is usually;
  ParseException: Encountered "  "0, "" at line 5, column 37.
    Was expecting:
    &lt; NEWLINE > ...</p>
  
  <p>Apache Pig version 0.12.0-cdh5.3.0</p>