10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
The awk below executes and produces the current output. it skips the header in row 1 and prints $4,$5,$6 and then adds the header row back.
The problem is that it keeps the tailing tab and prints it in front of $1. I could add a pipe to remove the tab, but is there a better way to do it with on... (7 Replies)
Discussion started by: cmccabe
7 Replies
2. Shell Programming and Scripting
Hi All
I had requirement where I need to re-order columns in a file by using a control file.
here is the ctrl file
c1
c2
c3
source file
c3 | c1 | c2
a | b| c
I should create output file based on the ctrl file columns
o/p should look like this
c1 | c2 | c3
b| c|a
I wrote some... (9 Replies)
Discussion started by: gvkumar25
9 Replies
3. UNIX for Dummies Questions & Answers
Hello!
I have a tab delimited file with values in three columns. Some values occur in all three columns, other values are present in only one or two columns. I would like to sort the file so that rows with no missing values come first, rows with one missing values come next, and rows with two... (9 Replies)
Discussion started by: MBarrett1213
9 Replies
4. Programming
I have a class
and want to print values in MOD using
L = new Layer* ;
How can I print the values in MOD using this object L???
class Layer
{
public :
Model* MODP;
Model* MODS; (1 Reply)
Discussion started by: kristinu
1 Replies
5. Programming
Hi,
I have small problem to print float value in the fallowing code
float Cx, W,f=250000, Cr=92.00,pi=3.14;
W=2*pi*f;
Cx = 1/W.Cr; //Cx value will be come around like 7.07E-9.
printf("capacitance value: %.10f",Cx);
I am trying to print Cx value using above code but it was not... (3 Replies)
Discussion started by: veerubiji
3 Replies
6. UNIX for Dummies Questions & Answers
Hi,
I have the following code:
LIST=`ls | grep '.sql$'`
echo $LIST
The above code will give me something like..
file1.sh file2.sh file3.sh file4.sh file5.sh
I want to display the values into rows using echo like...
file1.sh
file2.sh (5 Replies)
Discussion started by: adshocker
5 Replies
7. Shell Programming and Scripting
hi people;
the similar topic is being opened in here and here but i have confused with following condition. so i wanted to open a seperate topic.
from my file.txt:...
...
...
110105-16:04:04 192.168.1.1 7.1j Port_NODE_MODEL_M_1_8 stopfile=/tmp/10544... (0 Replies)
Discussion started by: gc_sw
0 Replies
8. Shell Programming and Scripting
Hi
I am trying to retrieve values from a tab-delimited file.I am using
while read record
value=`echo $record | cut -f12`
done
Where 12 is the column no i want retieve and record is one line of the file.
But it is returning the full record.
Plz help (4 Replies)
Discussion started by: akashtcs
4 Replies
9. Shell Programming and Scripting
Hi,
I have a file that looks like this:
36-
9+
45-
43+
400-
700+
I want to put a space between the number and the -/+ sign. So the output file will look like this
36 -
9 +
45 -
43 +
400 -
700 + (3 Replies)
Discussion started by: kylle345
3 Replies
10. UNIX for Dummies Questions & Answers
At work, when I issue:
lpr -P$PRINTER -h filename
the file always prints a line then does a vertical tab off that first line instead of starting the new line at left.
It does this with every file I've tried, and I can't find any options that are set that would make things print this way.
I... (2 Replies)
Discussion started by: scaredinjuly
2 Replies