10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
This has no error
awk '($8==150) && ($4>=11.001 && $4 <= 12) && ($5>=91.001 && $5<=92){print}' OFS="\t" file
following are unable to run in csh
this is giving error awk: line 1: syntax error at or near not even working in terminal
awk '($'$gr'=='$grn') && ($'$ll'>='$Y' && $'$ll' <= '$Ym')... (1 Reply)
Discussion started by: nex_asp
1 Replies
2. Shell Programming and Scripting
First post on here. So I use csh shells for my research (physics... not a CS person). I am trying to rerun the same scripts, but there are ~10 files that have similar variables that I have to change for each different configuration, so I would like one central file for the variables I change that... (3 Replies)
Discussion started by: sabrepride
3 Replies
3. Shell Programming and Scripting
I am trying to call awk from a csh script using
awk '{print $1, -$2, $3}' $fvmod.vel > $fvmod.xzv
and getting awk: Command not found.
Running
awk '{print $1, -$2, $3}' $fvmod.vel > $fvmod.xzv
on the command line with the actual filenames works (2 Replies)
Discussion started by: kristinu
2 Replies
4. UNIX for Dummies Questions & Answers
Guys,
following is my issue:
------------------------
#!/bin/csh
# specify a counter
@ k = 1
# loop
while ($k < 3)
# read all text file with a specific number less than 3 in the last column of a record
foreach file ( *.txt)
# capture the line by passing the column... (1 Reply)
Discussion started by: znbhatti
1 Replies
5. Shell Programming and Scripting
hi, I have a csh script, which has
setenv X xyz etc
My shell is korn
Is there some way I can "source" this to have the variables in my current korn shell?
thanks (3 Replies)
Discussion started by: JamesByars
3 Replies
6. Shell Programming and Scripting
Hello Guys,
I was trying to obtain the information from the /etc/passwd file, here was my script:
38 echo -n "What's your login name? "
39 set logname=$<
40 echo "Your login name is $logname, your user's ID is `grep $logname /etc/passwd|awk -F: '{print $3}'`"
41 echo " Your home dir is... (1 Reply)
Discussion started by: tpltp
1 Replies
7. Shell Programming and Scripting
Hi Friends,
Could you pleas help me out..
I have an awk program which works fine while running it in the command prompt.
The awk program is
===============
awk 'BEGIN {
format="head -%d M2_Sales_N01.txt |tail -%d >M2_Sales_N01_%02d.txt\n"
n=0
m=0
}
{
if (n==0)
{
tmp=$1
n=1
}... (5 Replies)
Discussion started by: bikas_jena
5 Replies
8. Shell Programming and Scripting
Hi , i need to plot a x-y axis graph using AWK or CSH. Pls help.
The data is as follows:
1 3
2 1
3 4
4 2
5 4
where 1st column refers to x-coordinate and 2nd column refers to y-coordinate. Note that x-coordinate may not be in sequence and the no of set of coordinates is unknown... (3 Replies)
Discussion started by: Raynon
3 Replies
9. UNIX for Dummies Questions & Answers
Does anyone have any links where i can find informaton about migrating from windows to unix/linux? Itīs both servers and clients that is on discussion.
/Henke (2 Replies)
Discussion started by: henke
2 Replies
10. Shell Programming and Scripting
After I compile a C program, when I run it from a C shell script, it does not print out the results.
e.g:
myCFile.c: main(){printf("Hey");}
myCshScript: myCFile
This does not output "Hey" to the terminal window. I am not even sure if it is executed or not.
What should I do to see the... (2 Replies)
Discussion started by: barisgultekin
2 Replies