11-11-2008
append the line with the previous if it not start with 1=
How to append the line with the previous if it not start with 1=.
1=ttt, 2=xxxxxx, 3=4545
44545, 4=66666,
1=ttt, 2=xxxxxx, 3=34434
3545, 4=66666, 5=ffffff
6=uuuuuuu, 7=ooooooo
1=ttt, 2=xxxxxx, 3=311343545, 4=66666
1=ttt, 2=xxxxxx, 5=XAXAXA, 7=FDFD
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
I have a file which contains data as below
When we see no pipe character in the line. append those lines to the previous line with pipe character till we get the next line with pipe character with ~(concat with ~)
Input file looks like:
1080530944|001|john.l.bonner|Acknowledge|CN... (11 Replies)
Discussion started by: ainuddin
11 Replies
2. Shell Programming and Scripting
Hi all,
Please help me in providing sample code to append the following 4 lines in one row.
Input :
A1/EXT "BAPBSC10/07B/00" 523 090530 0115
RXOCF-430 HY1711 1
EXTERNAL ALARM
DOOR ALARM
Output should be :
A1/EXT "BAPBSC10/07B/00" 523 090530 0115 ... (8 Replies)
Discussion started by: sudhakaryadav
8 Replies
3. Shell Programming and Scripting
I'll try explain this as best I can. Let me know if it is not clear.
I have large text files that contain data as such:
143593502 09-08-20 09:02:13 xxxxxxxxxxx xxxxxxxxxxx 09-08-20 09:02:11 N line 1 test
line 2 test
line 3 test
143593503 09-08-20 09:02:13... (3 Replies)
Discussion started by: jesse
3 Replies
4. Shell Programming and Scripting
Hi,
I want to append # at the start of line wherever keyword xyz is found through stream editor? Is it possible? (18 Replies)
Discussion started by: db2cap
18 Replies
5. UNIX for Dummies Questions & Answers
hi,
i have some values in excel sheet as in below format:
122
144
222
555
666
etc....
i need to get the output in the below manner..
£122
£144
£222
£555
£666 (1 Reply)
Discussion started by: arunmanas
1 Replies
6. Shell Programming and Scripting
Hi,
I need help for below scenario.I have a flat file which is having records seperated by delimiters which will represent each record for oracle table.My Control file will consider each line as one record for that table. Some of the lines are aligned in two/three lines so that records are... (4 Replies)
Discussion started by: kannansr621
4 Replies
7. Shell Programming and Scripting
Hi All,
This is very urgent, I've a data file with 1.7 millions rows in the file and the delimiter is cedilla and I need to format the data in such a way that if the NF in the next row is less than 1, it will append that value to previous line.
Any help will be appricated.
Thanks,... (17 Replies)
Discussion started by: cumeh1624
17 Replies
8. UNIX for Dummies Questions & Answers
awk 'BEGIN{FS = "Ç"}
NR == 1 {p = $0; next}
NF > 1 {print p; p = $0}
NF <= 1 {p = (p " " $0)}
END {print p}' input.txt > output.txt
This is what the input data file looks like with broken lines
Code:
29863 Ç890000000 Ç543209911 ÇCHNGOHG
Ç000000001 Ç055 ... (4 Replies)
Discussion started by: cumeh1624
4 Replies
9. Shell Programming and Scripting
Hi, I have data as below.
36578019,005-923887317,UNMDL,20151230,2C3CCAAG4GH135448,L,TX,20160108,62,"030916 PPT TX AFF RPRT VALID AFF IN PDP WLL FWD TO
RYAN ON 031116 CB1619
",,
36580219,611-923785453,FC,20151209,ZACCJABT9FPC19274,L,TX,20160108,83,,,... (4 Replies)
Discussion started by: JSKOBS
4 Replies
10. Shell Programming and Scripting
Hi,
i have a file with multiple entries. After some tests with sed i managed to get the file output as follows:
lsn=X-LINK-IN0,apc=661:0,state=avail,avail/links=1/1,
00,2110597,2094790,0,81,529,75649011,56435363,
lsn=TM1ITP1-AM1ITP1-LS,apc=500:0,state=avail,avail/links=1/1,... (5 Replies)
Discussion started by: nms
5 Replies
LEARN ABOUT DEBIAN
wml::des::imgbg
wml::des::imgbg(3) EN Tools wml::des::imgbg(3)
NAME
wml::des::imgbg - Background Images
SYNOPSIS
#use wml::des::imgbg
<: $file = &imgbg($base, $direction, $content, $pixels, $format); :>
<body ... background=<imgbg [attributes]> ...>
DESCRIPTION
The usual purpose of this tag is to create a PNG or GIF image containing a background image and to expand to its filename. Its contents is
specified via the "content" attribute by use of size/color pairs.
ATTRIBUTES
"base"
Usually the created images are named imgbg-xxxxxx.png where "xxxxxx" is the content id of the image. When you use a "base=foo"
attribute, then the resulting files are named foo.imgbg-xxxxxx.png. Actually you can even use a complete filename including a
directory prefix, i.e. when you use "base=../../common/foo" attribute, then the images are created as
../../common/foo.imgbg-xxxxxx.png.
And for most flexibility when no base is specified and the variable "BGIMG_BASE" is defined (usually from within a .wmlrc file via
"-DBGIMG_BASE~path/to/imgbg/dir/base") it is used. Use this feature to redirect the created images to a particular directory.
You may also use the variable "IMAGE_BASE" which defines in a single line all base names for images generated by WML.
"format"
By default, GIF images are generated. This attribute lets you use an alternate image format (actually only PNG and GIF are recognized).
You may also change the default format with the variable "IMAGE_FORMAT".
"direction"
Specifies the color change direction of the image: ``"h"'' for horizontal (default) or ``"v"'' for vertical.
"pixels"
Size of the image in the other direction, 1 by default.
"content"
This is a comma-separated list of size/color specifications ``pixels":#"rrggbb":#"rrggbb":"slices''
The last two arguments are optional, only present for gradient images. In this case, a linear gradient line is drawn from color 1 to
color 2, with slices different colors.
To get a background with two columns, a black one with 150 point in size and a white one which fills the rest of the page use
``"150:#000000,1200:#ffffff"''.
AUTHORS
Ralf S. Engelschall
rse@engelschall.com
www.engelschall.com
Denis Barbier
barbier@engelschall.com
REQUIRES
Internal: P1, P2, P3
SEE ALSO
HTML <"body"> tag.
EN Tools 2014-04-16 wml::des::imgbg(3)