I have to compare records in two files. It can be done using gawk/awk but i am unable to do it. Please help me
File1
ABAAAAAB BC asa sa
ABAAABAA BC bsa sm
ABBBBAAA BC bxz sa
ABAAABAB BC csa sa
ABAAAAAA BC dsa sm
ABBBBAAB BC dxz sa
File 2
ABAAAAAB BC aas ba
ABAAAAAB BC asa sa... (6 Replies)
Hai
I am using
bash-2.03$ bash --version
GNU bash, version 2.03.0(1)-release (sparc-sun-solaris)
I am not able to use gawk command its showing command not found , why ?
Eg:
awk 'NR==1' fix.txt | gawk 'BEGIN { FIELDWIDTHS = "3 2" } { printf($1"|"$2); }'... (3 Replies)
Hey guys need your help with an gawk script... here's what I have so far
gawk '^d/ {printf "%-20s %-10s %-10s %-10s %-4s%2s %5s\n",$9,$1,$3,$4,$6,$7,$8}' ls.kbr
The file ls.kbr is a capture of 'ls-al'
What I want gawk to do is:
1) Find only directories (this is working)
2) skip lines... (2 Replies)
Hi.
I'm having trouble using gawk within a bash script and I can't figure out why.
I have a command that takes in a data file with two columns, the first one numbers and the second words. My code takes each line, and prints the word its corresponding number of times. The code works from the... (2 Replies)
Hi,
I am using the script to print the portion of the file containing a particular string. But it is giving error "For Reading (No such file or directory). I am using cygwin as unix simulator.
cat TT35*.log | gawk -v search="12345678" '
/mSOriginating /,/disconnectingParty/ {
... (1 Reply)
People,
Ive been trying to make a script but i just cant figure it out.
Problem/ Case:
I have a logfile.txt that contains data. The only two things i need to filter on = $1 (date), $6 (errorcode).
In the script i am trying to make, u need to fill in a date. So he searches on that date... (11 Replies)
hi i've already created this script. When I execute the script it takes the argument and compares it to the 3rd column of the script. What I was wondering if I could get some help with is. I want to add another column to the script and it will be the result of a set number for example, (2000 - 3rd... (3 Replies)
I am trying to use gawk to search a file and put the second value of the string into a string.
gawk -F: '$1~/CXFR/ {print $2}' go.dat
Below is the file 'go.dat'
====================
HOME :/
CTMP :/tmp
CUTL :/u/rdiiulio/bin
CWRK :/u/work
CXFR :/u/xfer
... (1 Reply)
Hello,
This is a problem I've worked on a while and can't figure out.
There is a file.txt
..some stuff..
]
]
..some stuff..
The Awk program is trying to extract the year portion of the birth and death ("98: and "2nd C.") using the below technique
#!/bin/awk
@include... (5 Replies)
Discussion started by: Mid Ocean
5 Replies
LEARN ABOUT DEBIAN
smfsh
SMFSH(1)SMFSH(1)NAME
smfsh - SMF shell
SYNOPSIS
smfsh [ -V ] [ file ]
OPTIONS -V Print libsmf version and exit.
file Load the file.
DESCRIPTION
smfsh, an "SMF shell", is an interactive, command-driven frontend to libsmf, useful for modifying MIDI files by hand. It started its life
as a debugging aid for libsmf.
There are four groups of commands: SMF level, track level, event level, and others.
SMF LEVEL COMMANDS
SMF level commands display or change properties of smf (i.e. the MIDI file) as a whole.
save file
Save a file. If the file name is not given, the last file name is used.
Note that this will not ask for confirmation.
load file
Load a file. If the file name is not given, the last file name is used.
Instead of using "load", you can pass the file name on the command line.
ppqn new-ppqn
Show (if used without parameter) or change PPQN (Pulses Per Quarter Note, aka Division).
format new-format
Show (if used without parameter) or change format.
tempo Show tempo map. Tempo map is computed automatically from the SMF contents - to modify a tempo, just add a Tempo Change event using
"add" command.
length Show total length of the song. Just like the tempo map, file length is computed from the SMF contents.
TRACK LEVEL COMMANDS
Track level commands display or change properties of tracks. SMF may contain one or more tracks.
tracks Show the list of tracks in the SMF.
track track-number
Show details of a track (if called without parameter), or select track with a given number - for example in order to display
("events") the events it contains.
trackadd
Create new track.
trackrm track-number
Remove the track. If the track number is not given, this will remove the track currently selected.
EVENT LEVEL COMMANDS
Event level commands display or change properties of events. Events are grouped into tracks. Track may contain any number of events,
including zero.
events Show the list of events in the current track.
event event-number
Show information about a current event (if used without parameter) or select the event.
add time-in-seconds midi-message-as-hex
Add new event to the currently selected track.
rm event-number
Remove the event. If the event number is not given, this will remove the event currently selected.
OTHER COMMANDS
There are three commands in the "other" category - "help", "version", and "exit". Their meaning should be self expanatory.
smfsh 1.3 21 March 2010 SMFSH(1)