I have a file with
aaa,bbb,ccc,dddd,eee,xyz
aaa,bbb,ccc,dddd,eee,xyz,12345,rty
aaa,bbb,ccc,dddd,eee,xyz,12345,rty,tsrt
1. line columns are not fixed
2. all words are seperated by comma
what i want is always the string after last comma.
regards,
Senthil... (9 Replies)
I have a requirement in which i have to read a file which has multiple columns seperated by a pipe "|" from this i have to read each column values seperately and create a comma seperated row for the column and write to another file.
eg:
Input file:
ColA ColB
1 2
2 x
3 y... (5 Replies)
Hi,
I have a table in Db2 with data say
id_1 phase1
id_1 phase2
id_1 phase3
id_2 phase1
id_2 phase2
I need to concatenate the values like
id_1 phase1,phase2,phase3
id_2 phase1,phase2
I tried recursive query but in vain as the length of string to be concatenated in quite long. ... (17 Replies)
Hi,
I am new to shell scripting, i have requirement can any one help me out in this regrads,
in directory i have file like invoice1.txt, invoice2.txt in each file i have fixed number of columns, 62 in number but they are randomly arranged.like
for first file invoice1.txt can have columns... (5 Replies)
Hi,
I have a requirement with,
No~Dt~Notes
1~2011/08/1~"aaa
bbb
ccc
ddd
eee
fff
ggg
hhh"
Single column alone got splitted into multiple lines.
I require the output as
No~Dt~Notes
1~2011/08/1~"aaa<>bbb<>ccc<>ddd<>eee<>fff<>ggg<>hhh"
mean to say those new lines to be... (1 Reply)
Hi ,
Can You Please let Know How use unix uniq command on a single column for deleting records from file
with Below Structure.Pipe Delimter File .
Source
Name | Account_Id
A | 101
B... (2 Replies)
Hey guys, I have a column that consists of string and integer values without a distinctive deliminator, looking like this...
7ASA
14LAL
245FOO
656MOM
87577DAD
...
I want to split the column into two columns, one containing the numbers and one containing the text part.
edit: numbers... (3 Replies)
Hi,
I have pipe separated file which contains some data having comma(,) in it. I want to remove the comma(,) only from particular column without changing data in other columns.
Below is the sample data file, I want to remove the comma(,) only from 5th column.
$ cat file1
ABC | DEF, HIJ|... (6 Replies)
Hello everyone,
i need to replace in the second column of my csv file, points by nothing and dash by comma like this:
Input:
1 2 1;12.111.312-2;1.2;2;1-3
2 1 1;11.212.331-1;3.3;1;2-2
Output:
1 2 1;12111312;2;1.2;2;1-3
2 1 1;11212331;1;3.3;1;2-2
SED or PERL commands preferably.
... (7 Replies)
Hi All,
I am trying to output uniq values per column. see file below. can you please assist? Thank you in advance.
cat names
joe allen ibm
joe smith ibm
joe allen google
joe smith google
rachel allen google
desired output is:
joe allen google
rachel smith ibm (5 Replies)
Discussion started by: Apollo
5 Replies
LEARN ABOUT DEBIAN
carp::datum::strip
Datum::Strip(3pm) User Contributed Perl Documentation Datum::Strip(3pm)NAME
Carp::Datum::Strip - strips most Carp::Datum calls lexically
SYNOPSIS
use Carp::Datum::Strip qw(datum_strip);
datum_strip("-", "-");
datum_strip($file, "$file.new", ".bak");
DESCRIPTION
This module exports a single routine, datum_strip(), whose purpose is to remove calls to "Carp::Datum" routines lexically.
Because stripping is done lexically, there are some restrictions about what is actually supported. Unless the conventions documented in
Carp::Datum are followed, stripping will be incorrect.
The general guidelines are:
o Do not use here documents or generalized quotes (qq) within assertion expression or tags. Write assertions using '' or "", as
appropriate.
o Assertions can be safely put on several lines, but must end with a semi-colon, outside any string.
There are two calls that will never be stripped: VERIFY() and DTRACE(). The VERIFY() is meant to be preserved (or "DREQUIRE" would have
been used). "DTRACE", when called, will be remapped dynamically to some "Log::Agent" routine, depending on the trace level. See
Carp::Datum for details.
INTERFACE
The interface of the datum_strip() routine is:
"datum_strip" old_file, new_file, [ext]
The old_file specifies the old file path, the one to be stripped. The stripped version will be written to new_file.
If the optional third argument ext is given (e.g. ".bak"), then old_file will be renamed with the supplied extension, and new_file will
be renamed old_file. Renaming only occurs if stripping was successful (i.e. the new file was correctly written to disk).
The lowest nine "rwx" mode bits from old_file are preserved when creating new_file.
Both old_file and new_file can be set to "-", in which case STDIN and STDOUT are used, respectively, and no renaming can occur, nor any
mode bit propagation.
Returns true on success, "undef" on error.
AUTHORS
Christophe Dehaudt and Raphael Manfredi are the original authors.
Send bug reports, hints, tips, suggestions to Dave Hoover at <squirrel@cpan.org>.
SEE ALSO Carp::Datum(3).
perl v5.10.0 2006-04-13 Datum::Strip(3pm)