row count header to the sequential file
Moderators: chulett, rschirm, roy
Show us 1) exactly what you have (your source), and 2) exactly your desired output (your reformatted source).reshma11 wrote:I have a source oracle table,transformer and sequentail file. when i run this job i want to see number of records count + all records in sequentail file.
row count: 2
column1 column2
1 XXXX
2 XXX
Wrap your post in code tags, which will preserve formatting (basically using monospaced font for the code block, example):
Code: Select all
column1 column2
1 XXXX
2 XXX
In my case, it was to test for partial/failed FTP's, where the file already contained a header with the number of expected records. So in my case, I chose to use a Unix script, and abort if actual records <> expected records.
Some people are the Michael Jordan's of Datastage. I'm more like Muggsy Bogues
it is working
#!/bin/ksh
$var
var=`cat /***/***/test.txt | wc -l`
echo "row count : $var" > /***/**/test1.txt
cat /***/***/test1.txt >> /****/***/test.txt
Thank you.
$var
var=`cat /***/***/test.txt | wc -l`
echo "row count : $var" > /***/**/test1.txt
cat /***/***/test1.txt >> /****/***/test.txt
Thank you.