how to eliminate first two rows in seqential file
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 48
- Joined: Sat Oct 22, 2005 9:56 am
how to eliminate first two rows in seqential file
hi all,
how to eliminate first two rows from source seqential file
thanks
Stheesh bab
how to eliminate first two rows from source seqential file
thanks
Stheesh bab
Plot No – B4, Jeevan Akshyay apts
8/14, 2nd Main Road, Jaya Nagar
Tambaram sanitorium,
Chennai-47.
smandepudi@gmail.com
8/14, 2nd Main Road, Jaya Nagar
Tambaram sanitorium,
Chennai-47.
smandepudi@gmail.com
Re: how to eliminate first two rows in seqential file
Hi,sateeshbabu wrote:hi all,
how to eliminate first two rows from source seqential file
thanks
Stheesh bab
For that u can use (Head -2) or else go before routine
P.S: make it clear where you want to use that so that you can get the clear picture you want like(Sequencer's or in seqentail file itself)
Regards..Naveen.K
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
head -2 gives the first two rows - it does not eliminate them.Naveen.K wrote:For that u can use (Head -2) or else go before routine
Some shells allow the form head +2 which will eliminate the first two lines.
Otherwise use @INROWNUM > 2 as a constraint expression in a Transformer stage downstream of the Sequential File stage, running the Transformer stage in sequential execution mode.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
senthilt1 - Hint: The "@INROWNUM" and "@OUTROWNUM" mnemonics are available in the Transform stage.
<a href=http://www.worldcommunitygrid.org/team/ ... TZ9H4CGVP1 target="WCGWin">
</a>
</a>
Alternatively, you can enable Row Number Column in the sequential file stage. In the downstream transformer have a constraint as
Code: Select all
rowNumberColumn > 1
use filter in options of seq file /usr/bin/sed '1,2d'
use filter in options of sequential file
by using this unix command
/usr/bin/sed '1,2d'
by using this unix command
/usr/bin/sed '1,2d'