Welcome to Basic Intro with Stage Series, We are going to look into HEAD stage ( Developmet/Dubug Categoty). It can have a single input link and a single output link.
The Head Stage selects the first N rows from each partition of an input data set and copies the selected rows to an output data set. You determine which rows are copied by setting properties which allow you to specify:
- The number of rows to copy
- The partition from which the rows are copied
- The location of the rows to copy
- The number of rows to skip before the copying operation begins.
a) Job Design
Here we have selected the stage properties as below :
b) Head Stage Properties :
This will fetch the top 10 rows from each partition
But, we can select 10 rows from any single or more partition, for that select "All Partition" as FALSE and select the partition ( 0,1 or more ) from which you need the tailed rows.
- As per design, send the head o/p to a seq files.