I got a sample file like this.
$ cat test
12|13|100|s
12|13|100|s
100|13|100|s
12|13|100|s
I want to replace all 100 by 2000 only in 3rd field using "awk"
This is replacing all 100's :-(
$ awk -F "|" '{gsub( /100/,"2000");print}' test
12|13|2000|s
12|13|2000|s
2000|13|2000|s... (5 Replies)
can someone help me with the find and replace command.
I have a input file which is in the below format:
0011200ALN00000000009EGYPT 000000000000199900000
0011200ALN00000000009EGYPT 000000000000199900000
0011200ALN00000000008EGYPT 000000000000199800000
0011200ALN00000000009EGYPT ... (20 Replies)
Hi,
I have a pipe delimited file. I need to change the timestamp in the second field in all the records to a specific value. can you please let me know how i can do it?
sample file with 2 reocrds. The time i need to change is in red below.
Please let me know how I can change only... (7 Replies)
I have a rather complicated search and replace I need to do among several dozen files and over a hundred occurrences. My site is written in PHP and throughout the old code, you will find things like
die("Operation Aborted due to.....");
For my new design skins for the site, I need to get... (2 Replies)
Hello All
I have always had a question about find and replace in Vi. As this uses Vi, sed, and RegEx I never knew how or where to post the question but I thought I would give it a shot here. Say I have a text file filled with the following:
Sue, your IP address is 192.168.1.10 which is... (4 Replies)
Hi experts,
As i am a novice unix player...so need help for the below query...banged my head from quite a while...:confused:
i have a set of html files, in which i need to search for string "Page"(case sensitive) and then replace the same with some numeric code ,say, "XXX1234".
Here in... (1 Reply)
I have three variables $a, $b and $c
$a = file_abc_123.txt
$b = 123
$c = 100
I want to search if $b is present in $a. If it is present, then i want to replace that portion by $c.
Here $b = 123 is present in "file_abc_123.txt", so i need the output as "file_abc_100.txt'
How can this be... (3 Replies)
Hello,
I have a file with multiple lines like this:
/film/4295/"_class="titre_article">50/50I would like to change all occurence of / after > with _ to have this:
/film/4295/"_class="titre_article">50_50Thank you
edit:
This could also be change all / starting with the 4th occurrence... (2 Replies)
Hello,
I have a csv file with "^" as text delimiters and "|" as field delimiters. It's converted from a xls file. One record looks like this:
^Tablete Internet^|Archos|501838|^Tableta Internet ARCHOS 80 G9
...| ...
(more lines)
... "501|838"^|330.00|USD|sl|12|0|Link|^router wireless 150... (10 Replies)
Hi,
Can somebody tell whats wrong with "find and replace perl code".
I wanted to find "\n".write(status,data" and replace with "\n",data" in multipls files.
#!/usr/bin/perl
my @files = <*.c>;
foreach $fileName (@files) {
print "$fileName\n";
my $searchStr0 =... (4 Replies)
Discussion started by: chettyravi
4 Replies
LEARN ABOUT X11R4
gtf
GTF(1) General Commands Manual GTF(1)NAME
gtf - calculate VESA GTF mode lines
SYNOPSIS
gtf h-resolution v-resolution refresh [-v|--verbose] [-f|--fbmode] [-x|--xorgmode]
DESCRIPTION
Gtf is a utility for calculating VESA GTF modes. Given the desired horizontal and vertical resolutions and refresh rate (in Hz), the
parameters for a matching VESA GTF mode are printed out. Two output formats are supported: mode lines suitable for the Xorg xorg.conf(5)
file, and mode parameters suitable for the Linux fbset(8) utility.
OPTIONS
-v|--verbose
Enable verbose printouts This shows a trace for each step of the computation.
-x|--xorgmode
Print the mode parameters as Xorg-style mode lines. This is the default format.
-f|--fbset
Print the mode parameters in a format suitable for fbset(8).
SEE ALSO xorg.conf(5)AUTHOR
Andy Ritger.
This program is based on the Generalized Timing Formula (GTF(TM)) Standard Version: 1.0, Revision: 1.0. The GTF Excel(TM) spreadsheet, a
sample (and the definitive) implementation of the GTF Timing Standard is available at <ftp://ftp.vesa.org/pub/GTF/VTF_V1R1.xls>.
X Version 11 xorg-server 1.6.0 GTF(1)