Hi, Rahul,
Embedding mode does not work with grunt. Please run as a script file.

Daniel

On Wed, Jan 11, 2012 at 10:24 PM, rahul raghavendhra <
[email protected]> wrote:

> i have downloaded jython jar and installed it.. but i couldnt run pig
> scripts using py script... i have created a .py in pig/bin forder.. how to
> run the pig.. pig wiki is not so clear..please help.
>
> when i run the script inside grunt as run sample.py
>
> i got the following error
>
> grunt> #!/usr/bin/python
> grunt> from org.apache.pig.scripting import Pig
> 2012-01-12 11:50:18,637 [main] ERROR org.apache.pig.tools.grunt.Grunt -
> ERROR 1000: Error during parsing. Encountered " <IDENTIFIER> "from "" at
> line 2, column 1.
>
>
> when i inside bin as pig sample.py
>  i got this error..
> hadoop1@karthi-ericsson:/usr/local/pig/bin$ pig sample.py
> 2012-01-12 11:53:14,475 [main] INFO  org.apache.pig.Main - Logging error
> messages to: /usr/local/pig/bin/pig_1326349394473.log
> 2012-01-12 11:53:14,485 [main] INFO  org.apache.pig.Main - Run embedded
> script: jython
> 2012-01-12 11:53:14,597 [main] INFO
> org.apache.pig.backend.hadoop.executionengine.HExecutionEngine - Connecting
> to hadoop file system at: hdfs://localhost:54310
> 2012-01-12 11:53:14,736 [main] INFO
> org.apache.pig.backend.hadoop.executionengine.HExecutionEngine - Connecting
> to map-reduce job tracker at: localhost:54311
> hadoop1@karthi-ericsson:/usr/local/pig/bin$
>
>
> please help
> ./rahul
>

Reply via email to