sequential file error
Moderators: chulett, rschirm, roy
sequential file error
Hi
I am trying to remove first line in my input sequential file. i am using filter command sed '1d' to do this.
i am getting error saying
test..Sequential_File_0.DSLink3: ds_seqopen() - Error in filter command "sed -n '1d'" -
test..Sequential_File_0.DSLink3: ds_seqopen() - Error in execv() - No such file or directory
How can i correct this error?
Thanks
I am trying to remove first line in my input sequential file. i am using filter command sed '1d' to do this.
i am getting error saying
test..Sequential_File_0.DSLink3: ds_seqopen() - Error in filter command "sed -n '1d'" -
test..Sequential_File_0.DSLink3: ds_seqopen() - Error in execv() - No such file or directory
How can i correct this error?
Thanks
Re: sequential file error
deepthi wrote:Hi
I am trying to remove first line in my input sequential file. i am using filter command sed '1d' to do this.
i am getting error saying
test..Sequential_File_0.DSLink3: ds_seqopen() - Error in filter command "sed -n '1d'" -
test..Sequential_File_0.DSLink3: ds_seqopen() - Error in execv() - No such file or directory
How can i correct this error?
Thanks
Why filter you can set this in the Sequential File it self, follow below steps:
go to Output tab-->Properties tab-->in the Options, select First Line is Column Names= True, what it means is : if set true, the first line of a file contains column names/row on writing and is ignored on reading.
Regards,
Abburi
Abburi
Re: sequential file error
deepthi wrote:Hi
I am trying to remove first line in my input sequential file. i am using filter command sed '1d' to do this.
i am getting error saying
test..Sequential_File_0.DSLink3: ds_seqopen() - Error in filter command "sed -n '1d'" -
test..Sequential_File_0.DSLink3: ds_seqopen() - Error in execv() - No such file or directory
How can i correct this error?
Thanks
Why filter you can set this in the Sequential File it self, follow below steps:
go to Output tab-->Properties tab-->in the Options, select First Line is Column Names= True, what it means is : if set true, the first line of a file contains column names/row on writing and is ignored on reading.
Regards,
Abburi
Abburi
-
- Participant
- Posts: 89
- Joined: Sat Jul 24, 2010 11:33 pm
I have the same issue. I have sequential in the source with 2nd line as column name and first line tells about UTF8. I have tried to set the first line as column but it did not work. I have achieved using the sed command but can i handle this in job since i have to use shells scripts for other purpose after the job completes ?
Another but lengthy solution
Try out this.
Go to your UNIX box and count the total number of records in your sequential file.
wc -l FileName
It will give you the total number of lines in that file.
Suppose you get total number of lines = m, then reduce 2 from m.
For example
n = m - 2
Then do this
tail -n FileName > NewFileName
Now Use NewFileName in your datastage job.
Try out this.
Go to your UNIX box and count the total number of records in your sequential file.
wc -l FileName
It will give you the total number of lines in that file.
Suppose you get total number of lines = m, then reduce 2 from m.
For example
n = m - 2
Then do this
tail -n FileName > NewFileName
Now Use NewFileName in your datastage job.
Arvind