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

parser should not require bincond/conditional operator to be within parenthesis

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • None
    • 0.9.0
    • None
    • None

    Description

      grunt> f = foreach a generate age > 21 ? 0 : 1;
      2010-12-17 07:45:15,966 [main] ERROR org.apache.pig.tools.grunt.Grunt - ERROR 1000: Error during parsing. Encountered " <FILTEROP> "> "" at line 1, column 28.

      The conditional operator needs to be put in parenthesis to get it to work . This not intuitive -
      grunt> f = foreach a generate (age > 21 ? 0 : 1);

      Attachments

        Issue Links

          Activity

            People

              xuefuz Xuefu Zhang
              thejas Thejas Nair
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: