thanx itkamaraj......that was very helpful...
but if there are multiple records like..
i/p
o/p
how to get this???
than in advance..previous solution was really helpful...
Moderator's Comments:
Please use code tags next time for your code and data.
Last edited by zaxxon; 08-02-2012 at 04:56 AM..
Reason: code tags, see PM
Hi all,
I have a file that looks like this...
##########
1zz2_15-43 1ouy_0-13-35 1.12619901947
2gfs_41-7 1yqj_3 0.793602121208
1bl7_11-3 1wbo_1-3-4 0.791065168287
1ywr_16-3 2ghl_22 0.956896171134
2exc_11-35 1pmq_13-15-87 0.597677672501
2bal_25-7 1ouk_17-19-21-228-58 0.668388304836... (6 Replies)
Hello,
I have two files that I need to compare and print out the line from file2 that has the first 6 fields matching the first 6 fields in file1. Complicating this are the following restrictions
1. file1 is only a few thousand lines at most and file2 is greater than 2 million
2. I need to... (7 Replies)
Hi everyone, happy new year!
Can someone teach me how I can print the last 2 fields of every line in a file (lines don't have uniform number of fields), for example:
input file:
aaa bbb ccc ddd
eee fff ggg
hhh iii jjj
kkk lll mmm nnn ooo
output:
ccc ddd
fff ggg
iii jjj
nnn ooo
... (2 Replies)
Hello,
I have a text file with the following fields:
RecordNumber
Name
Email
Date
Notes
Confirmed
MailingList
The problem is that each field is on a separate line. These seven fields repeat for the length of the file. What I want to do is to have a bash script or similar unitil EOF... (6 Replies)
input:
field1
field2
field3 field4
output:
"field1";"field2";"field3";"field4"
My input file is shown above and I want output as shown using awk. the length of field3 is fixed so, the space between field3 and field4 can vary according to the value of field3. I am new to unix, so... (1 Reply)
Hello All,
I am trying a one liner for finding the number of null columns in every line of my flat file.
The format of my flat file is like this
a|b|c|d||||e|f|g|
a|b|c|d||||e|f|g|
I want to count the number of fields delimited by "|" which are blank.
In above case the count should be... (6 Replies)
I am new to awk scripting.
I want to do a field by word (field) comparison of two files File1.txt and File2.txt.
The files contain a list of | (pipe) separated field.
**File 1:
-------------------
aaa|bbb|ccc|eee|fff
lll|mmm|nnn|ooo|ppp
rrr|sss|ttt|uuu|vvv**
File 2: ... (7 Replies)
Hi,
i have a scenario were i should compare a few fields from each line then increment a variable based on that.
Example file
989878|8999|Y|0|Y|N|V
989878|8999|Y|0|N|N|V
989878|8999|Y|2344|Y|N|V
i have 3 conditions to check and increment a variable on every line
condition 1 if ( $3... (4 Replies)
Hi All,
I have situation where my file looks like this log.file. ID Start time IP SQL
1256152 05-Aug-15, 11:25:06 MST 10.54.20.33 Select * from TES
1004768 05-Aug-15, 11:25:06 MST 10.54.20.33 Select dummy
323323 05-Aug-15, 12:00:06 MST 10.15.20.77 ... (1 Reply)
Discussion started by: netdbaind
1 Replies
LEARN ABOUT LINUX
ppmtosixel
ppmtosixel(1) General Commands Manual ppmtosixel(1)NAME
ppmtosixel - convert a portable pixmap into DEC sixel format
SYNOPSIS
ppmtosixel [-raw] [-margin] [ppmfile]
DESCRIPTION
Reads a portable pixmap as input. Produces sixel commands (SIX) as output. The output is formatted for color printing, e.g. for a DEC
LJ250 color inkjet printer.
If RGB values from the PPM file do not have maxval=100, the RGB values are rescaled. A printer control header and a color assignment table
begin the SIX file. Image data is written in a compressed format by default. A printer control footer ends the image file.
OPTIONS -raw If specified, each pixel will be explicitly described in the image file. If -raw is not specified, output will default to com-
pressed format in which identical adjacent pixels are replaced by "repeat pixel" commands. A raw file is often an order of magni-
tude larger than a compressed file and prints much slower.
-margin
If -margin is not specified, the image will be start at the left margin (of the window, paper, or whatever). If -margin is speci-
fied, a 1.5 inch left margin will offset the image.
PRINTING
Generally, sixel files must reach the printer unfiltered. Use the lpr -x option or cat filename > /dev/tty0?.
BUGS
Upon rescaling, truncation of the least significant bits of RGB values may result in poor color conversion. If the original PPM maxval was
greater than 100, rescaling also reduces the image depth. While the actual RGB values from the ppm file are more or less retained, the
color palette of the LJ250 may not match the colors on your screen. This seems to be a printer limitation.
SEE ALSO ppm(5)AUTHOR
Copyright (C) 1991 by Rick Vinci.
26 April 1991 ppmtosixel(1)