# Pig Editor

The Pig Editor application allows you to define Pig scripts, run scripts, and view the status of jobs. For information about Pig, see Pig Documentation.

In Hue 3.5, a new assistant was added to the Pig Editor: Navigator.

Similarly to the Hive and Impala Editors, functions and Pig statements are made directly available from within the editor:

Navigator is:

- Sorted by category

- Searchable

- Auto-completable (as well as HDFS paths and Metastore tables)

So now, get started with Apache Pig!

## Pig Editor Installation and Configuration

Pig Editor is one of the applications installed as part of Hue.

## Starting Pig Editor

Click the Pig Editor icon () in the navigation bar at the top of the Hue browser page. The Pig Editor opens with three tabs:

- Editor - editor where you can create, edit, run, save, copy, and delete scripts and edit script properties.
- Scripts - script manager where you can create, open, run, copy, and delete scripts.
- Dashboard - dashboard where you can view running and completed scripts and view the log of a job.

## Installing the Sample Pig Scripts

Note: You must be a superuser to perform this task.

1. Click . The Quick Start Wizard opens.
2. Click Step 2: Examples.
3. Click Pig Editor.

### Scripts

#### Creating a Script

1. In either the Editor or Scripts screen, click New script. Edit the script as desired.
2. Click Edit Properties. In the Script name field, type a name for the script.
3. Click Save.

#### Opening a Script

1. Click the Scripts tab.
2. In the list of scripts, click a script.

#### Running a Script

1. Do one of the following:
   - In the Editor screen, click the Run button.
   - In the Scripts screen, check the checkbox next to a script and click the Run button.

#### Viewing the Result of Running a Script

1. Click the Dashboard tab.
2. Click a job.