01-31-2017
Thanks guys it worked perfectly
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I have the below file ...where some of the column values should replaced with desired values ....below file u can find that 3 column where ever 'AAA' comes should replaced with ' CC '
NOTE : we have to pass the column number ,AAA,CC (modified value) as the parameters to the code.
... (6 Replies)
Discussion started by: charandevu
6 Replies
2. Web Development
Hallo all,
I try to create a bash script but till now without any positiv results.
The script should replace different variables in a text file with the right xml values
Look at the following xml file:
file.xml
===================================
<?xml version="1.0"... (1 Reply)
Discussion started by: research3
1 Replies
3. UNIX for Dummies Questions & Answers
I have a file:
$somevar=somevalue
$anothervar=
$someothervar=45
I'd like to be able to replace the values in the file. I just don't know how exactly to use sed. I was thinking along the lines of:
cat file | sed "s/$somevar=/anotherval/g"
I was hoping this would make the... (2 Replies)
Discussion started by: mrwatkin
2 Replies
4. Shell Programming and Scripting
Hi All,
I'm looking for a script which can transpose field names from column headers to values in one column.
for example, the input is:
IDa;IDb;IDc;PARAM1;PARAM2;PARAM3;
a;b;c;p1val;p2val;p3val;
d;e;f;p4val;p5val;p6val;
g;h;i;p7val;p8val;p9val;
into the output like this:
... (6 Replies)
Discussion started by: popesk
6 Replies
5. Shell Programming and Scripting
Hello Expert,
I need to transpose Date-Timestamp based on same column values and calculate time difference. The input file would be as below and required output is mentioned in the bottom
INPUT File
========
08/23/2012 12:36:09 JOB_5340
08/23/2012 12:36:14 JOB_5340
08/23/2012... (2 Replies)
Discussion started by: asnandhakumar
2 Replies
6. Shell Programming and Scripting
Dear Friends,
I did the same question before in other thread, but I want to explain a little better my request.
I am looking for a way how to find and replace a values in two files using a reference a file where are the key to replace.
Basically, I want to keep a copy of the original file... (1 Reply)
Discussion started by: jiam912
1 Replies
7. Shell Programming and Scripting
I have the following input format:
AA00000712000 -0.17 0.90 -1.04 -0.37 -1.45 -1.13 -0.22 -0.34 -0.55 2.37 0.67 -0.48 -0.48
AA00000712001 0.15 0.03 0.47 0.62 2.04 1.14 0.29 -0.81 0.85 0.53 1.00 -0.10 -0.48
BB00000712000 1.32 -0.47 0.44 0.00 0.98 ... (4 Replies)
Discussion started by: ncwxpanther
4 Replies
8. Shell Programming and Scripting
Gents,
Please can you help me with this.
When column 49 == 2
Need to do the following changes;
Change previous row field (substr$0,45,4)-1
Change previous row field (substr$0,72,5)+2
Change actual row field (substr$0,40,4)+1
Change actual row field (substr$0,49,1)-1
Change actual... (6 Replies)
Discussion started by: jiam912
6 Replies
9. Shell Programming and Scripting
Gents,
Can you please help with this.
Input file
49955 2009 2
49957 2010 2
49959 2010 2
49961 2010 2
49963 2010 2
49789 2011 -174
49791 2011 2
49793 2011 2
49795 2011 2
49965 2011 170
49967 2011 2
49969 2011 2
49971 2011 2
49797 2012 -174
49799 2012 2 (8 Replies)
Discussion started by: jiam912
8 Replies
10. Shell Programming and Scripting
Gents,
Please i need your help.
Using the file2.txt i will like to replace values in file3.txt.
Example in file 2 column 1 is the value to find in file3.txt and replace with value in colunm2 (file2.txt).
Example
file2.txt
21 1209
22 1210file3.txt
SCI TB Timestamp Local : 8/30/17... (2 Replies)
Discussion started by: jiam912
2 Replies
LEARN ABOUT REDHAT
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)