Search Results

Search: Posts Made By: rajnikanth.1912
3,180
Posted By rajnikanth.1912
once you collect all these values into a file. ...
once you collect all these values into a file.


You can use AWK
to compare the values on the reqd column
and if the new value of date != old value of date then
you can print the old value...
3,180
Posted By rajnikanth.1912
Steps to be done. ------------------ 1)....
Steps to be done.
------------------

1). First get the list of all the values for ex

Priya , Prakash etc into a file.

using

cat file_name | cut -d ' ' -f4-4 | sort -u > temp_file.
...
7,462
Posted By rajnikanth.1912
How to pass values between awk and shell scripts
I know that we can call system command to execute shell script in awk.

but it does not return the result of the command executed , but only returns
the value of the command executoin status (...
5,996
Posted By rajnikanth.1912
echo "A,B,C,D" | awk -F, '{print NF}' Here...
echo "A,B,C,D" | awk -F, '{print NF}'

Here NF signifies number of fields.

Each field of the line will be marked as $1, $2 etc

you can use a loop , if condition to print the required fields.
15,060
Posted By rajnikanth.1912
You need to initialise the variables num and sum ...
You need to initialise the variables num and sum

#!/bin/ksh

a=12346
b=`expr length $a`
echo " length : $b"
typeset -i i=1
num=0
sum=0
while (( i <= $b ))
do
((num=$(echo "${a}" | cut -c...
Showing results 1 to 5 of 5

 
All times are GMT -4. The time now is 01:38 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy