06-03-2014
Thanks Chubler!
Can you please explain your code
Last edited by techedipro; 06-03-2014 at 12:14 AM..
Reason: typo
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have one large file, after every 200 line i have to split the file and the add header and footer to each small file?
It is possible to add different header and footer to each file? (1 Reply)
Discussion started by: ashish4422
1 Replies
2. Shell Programming and Scripting
I have one large file, after every 200 line i have to split the file and the add header and footer to each small file?
It is possible to add different header and footer to each file? (7 Replies)
Discussion started by: ashish4422
7 Replies
3. Shell Programming and Scripting
Hi All,
I am karthik. I am new to this forum. I have one requirement.
I have a file with header and footer.
Header may be like
HDR0001
or
FILE20090110
(Assume it is unknown so far, but i am sure there is a header in the file)
likewise file has the trailer too.
I just... (7 Replies)
Discussion started by: karthi_gana
7 Replies
4. Shell Programming and Scripting
Hi all,
I have a requirement to create a Header &Trailer for a file which is having 20 millions of records.
If I use the following method, i think it will take more time.
cat "Header"> file1.txt
cat Data_File>>file1.txt
cat "Trailer">>file1.txt
since second CAT command has to read all... (4 Replies)
Discussion started by: Raamc
4 Replies
5. Shell Programming and Scripting
How can we a shell script and pass date parameters .I have 3 files comming from Datastage with |" delimited
I need append 3 files as above: File1:
P0000|"47416954|"AU|"000|"INS|"0000|"|"20060601|"99991231|"|"|"|"|"01
File 2:... (2 Replies)
Discussion started by: e1994264
2 Replies
6. UNIX for Dummies Questions & Answers
Hi,
I want to add the below Header to all the files in sequence File1,File2,File3...etc
"ABC,<number of chracter in the file>"
e,g - If File1 is as below
pqrstuvdt
abcdefgh
then I want to add the above header into it ,So that File1 becomes as below
ABC,17
pqrstuvdt
abcdefgh
... (9 Replies)
Discussion started by: spari2
9 Replies
7. Shell Programming and Scripting
Hi All,
I am trying write a simple command using AWK and SED to this but without any success.
Here is what I am using:
head -1 test1.txt>test2.txt|sed '1d;$d' test1.txt|awk '{print substr($0,0,(length($0)-2))}' >>test2.txt|tail -1 test1.txt>>test2.txt
Input:
Header
1234567
abcdefgh... (2 Replies)
Discussion started by: nvuradi
2 Replies
8. Shell Programming and Scripting
Hi,
I need a script that validates a file header/detail/trailer. File layout is:
Header - Rec_Type|File_name|File_Date
Detail - Rec_Type|field1|field2|field3...
Trailder - Rec_Type|File_name|File_Date|Record_count
Sample Data:
HDR|customer_data.dat|20120709... (7 Replies)
Discussion started by: ash_sh
7 Replies
9. Shell Programming and Scripting
please see my requirement, I hope I am clear. (9 Replies)
Discussion started by: mirwasim
9 Replies
10. UNIX for Advanced & Expert Users
I have a EBCDIC multi layout file which has a header record which is 21 bytes, The Detail records are 2427 bytes long and the trailer record is 9 bytes long.
Is there a command to remove the header as well as trailer record and read only the detail records while at the same time not altering... (1 Reply)
Discussion started by: abhilashnair
1 Replies
LEARN ABOUT DEBIAN
catalyst::controller::sru
Catalyst::Controller::SRU(3pm) User Contributed Perl Documentation Catalyst::Controller::SRU(3pm)
NAME
Catalyst::Controller::SRU - Dispatch SRU methods with Catalyst
SYNOPSIS
package MyApp::Controller::SRU;
# use it as a base controller
use base qw( Catalyst::Controller::SRU );
# explain, scan and searchretrieve methods
sub explain {
my ( $self, $c,
$sru_request, # ISA SRU::Request::Explain
$sru_response, # ISA SRU::Response::Explain
) = @_;
}
sub scan {
my ( $self, $c,
$sru_request, # ISA SRU::Request::Scan
$sru_response, # ISA SRU::Response::Scan
$cql, # ISA CQL::Parser root node
) = @_;
}
sub searchRetrieve {
my ( $self, $c,
$sru_request, # ISA SRU::Request::SearchRetrieve
$sru_response, # ISA SRU::Response::SearchRetrieve
$cql, # ISA CQL::Parser root node
) = @_;
}
DESCRIPTION
This module allows your controller class to dispatch SRU actions ("explain", "scan", and "searchRetrieve") from its own class.
METHODS
index : Private
This method will create an SRU request, response and possibly a CQL object based on the type of SRU request it finds. It will then pass the
data over to your customized method.
SEE ALSO
o Catalyst
AUTHOR
Brian Cassidy <bricas@cpan.org>
COPYRIGHT AND LICENSE
Copyright 2005-2009 by Brian Cassidy
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
perl v5.12.4 2009-12-02 Catalyst::Controller::SRU(3pm)