Support Questions

Find answers, ask questions, and share your expertise

How to run Python script in Hue through oozie

avatar
Expert Contributor

Hi, can someone give me a few basic steps on how to go about running a simple python script in Hue using Oozie such as reading a hive table and write the data to a csv file. Some steps like where I enter the python code and how to run it through HUE interface to help me get started. An example python script will also be very helpful. Thanks.

1 ACCEPTED SOLUTION

avatar
Expert Contributor

The solution was to put the python script in Hue->Query->Editor->Spark in the Libs field with the full path of the python script example: Libs:  /user/userxyz/myscript.py and run the query. Clicking the job_xxxxx link will show if the script ran successfully or not.

View solution in original post

2 REPLIES 2

avatar
Super Guru
The following link:
http://gethue.com/use-the-shell-action-in-oozie/

from Hue website is about how to setup script shell in Hue Oozie interface. Python script will be similar. I suggest you go through the documentation on Hue for more detailed info.

avatar
Expert Contributor

The solution was to put the python script in Hue->Query->Editor->Spark in the Libs field with the full path of the python script example: Libs:  /user/userxyz/myscript.py and run the query. Clicking the job_xxxxx link will show if the script ran successfully or not.