Search Results

Search: Posts Made By: pravin27
4,587
Posted By pravin27
Hi, Can you try job_depends command of autosys...
Hi,
Can you try job_depends command of autosys ?
Thanks
Pravin
1,656
Posted By pravin27
Hi , Try new code from post #6. Thanks ...
Hi ,
Try new code from post #6.

Thanks
Pravin
6,083
Posted By pravin27
export Numbr_Parms=$# export a=1 while [ $a...
export Numbr_Parms=$#
export a=1
while [ $a -le $Numbr_Parms ]
do
eval export DBName_$a=\$$a
echo DBName_$a
eval echo \$$DBName_$a
a=`expr $a + 1`
done
1,656
Posted By pravin27
RavinderSingh13, One doubt here , why 179 183...
RavinderSingh13,
One doubt here , why 179 183 is in your o/p
o/p in the post of before4 does not include it.
Little modification if you want to exclude 179 183
awk 'NR==1{first=$0;prev=$0;next }...
1,460
Posted By pravin27
try below awk '{if (a[$1FS$2FS]) {a[$1FS$2FS]...
try below
awk '{if (a[$1FS$2FS]) {a[$1FS$2FS] =a[$1FS$2FS]","$3} else {a[$1FS$2FS]=$3}} END {for (key in a) { print key a[key]}}' testfile
1,507
Posted By pravin27
Hi RudiC, I think solution need 6 character to...
Hi RudiC,
I think solution need 6 character to extract instead 7 substr($1, 5, 7)

Thanks
Pravin
2,873
Posted By pravin27
You can use getline in awk to get the desire...
You can use getline in awk to get the desire output. i have modified your code as below.
nawk '{print " " $NF}' line2 > nawk6
nawk '
{CNF = (length()-10)/7
...
2,873
Posted By pravin27
You can modify your for loop as below. for...
You can modify your for loop as below.
for (i=2; i<=CNF+2; i++) {printf "%7s", T[i]; if ( i == 19) {printf "%7s", "2.979"}}
2,995
Posted By pravin27
Convert your date to seconds and then compare. ...
Convert your date to seconds and then compare.
dProcDate="2016-02-29"
dCurrent="2016-05-31"

dProcDate_sec=$(date -d"$dProcDate" '+%s')
dCurrent_sec=$(date -d"$dCurrent" '+%s')

if [...
2,796
Posted By pravin27
sed '/\[\/\]/a added' filename
sed '/\[\/\]/a added' filename
1,209
Posted By pravin27
awk -F";" '{if ($3"|"$4 != prev ) {print...
awk -F";" '{if ($3"|"$4 != prev ) {print }prev=$3"|"$4}' filename
2,733
Posted By pravin27
Could this help you ? #!/bin/sh ...
Could this help you ?

#!/bin/sh

print_output () {
myArray=$1
eval echo \${$myArray }
}

cd /path/to/yourdir
ls | paste - - - - | while read line
do
eval FileArray=("${line}")...
1,041
Posted By pravin27
#!/bin/sh function one () { echo...
#!/bin/sh

function one ()
{
echo "Who is here"
read name
echo "Who old are you $name"
read age

[[ "$name" == "Sam" ]] && Sam=$age
[[ "$name" == "Jack"...
21,009
Posted By pravin27
Modified code #!/bin/sh _fileName=$1 ...
Modified code
#!/bin/sh

_fileName=$1
_tableName=$(basename ${_fileName})
_SQLFile=${_tableName}".sql"

tr "|" "," < ${_fileName} | awk -F"," -v tableNM=$_tableName -v sqlfn=${_SQLFile}...
21,009
Posted By pravin27
Could this help you ? #!/bin/sh ...
Could this help you ?

#!/bin/sh

_fileName=$1
_tableName=$(basename ${_fileName})
_SQLFile=${_tableName}".sql"

tr "|" "," < ${_fileName} | awk -F"," -v tableNM=$_tableName -v...
3,336
Posted By pravin27
Perl #!/usr/bin/perl use Date::Calc qw...
Perl
#!/usr/bin/perl
use Date::Calc qw (Add_Delta_DHMS);
$dateParam=shift;
@date1=unpack("A4 A2 A2", $dateParam);
@date2 = Add_Delta_DHMS(@date1,0,0,0,-1,0,0,0);
print "@date2 \n";
...
2,236
Posted By pravin27
Hi Ritakdm, Could this help you ? awk...
Hi Ritakdm,

Could this help you ?

awk -F"\t" '{if (FILENAME != "master.txt" ) { a[$1]=$2;next}}
{n2=split ($2,P," "); n3=split($3,Q," "); n4=split ($4,R," "); printf "\n"$1FS$2FS;
for...
27,072
Posted By pravin27
I am not sure about this. Could you please...
I am not sure about this.

Could you please try with below code ? just to verify image appear in the email or not (working below code fine at my end)
src=http://i.imgur.com/4pGDdQM.gif
2,236
Posted By pravin27
awk -F"\t" '{if (FILENAME != "master.txt" ) {...
awk -F"\t" '{if (FILENAME != "master.txt" ) { a[$1]=$2;next}}
{split ($2,P," "); split($3,Q," "); split ($4,R," "); print $1"\t"$2"\t"a[P[1]],a[P[2]]"\t"$3"\t"a[Q[1]],a[Q[2]]"\t"$4,a[R[1]],a[R[2]]}'...
27,072
Posted By pravin27
Hi Anji, You need to provide full path of...
Hi Anji,

You need to provide full path of src image file. For test purpose I have added below src image to your mail.tx and it works fine.
replace below code
...
27,072
Posted By pravin27
Could you please upload mail.txt ? It help us to...
Could you please upload mail.txt ? It help us to reproduce the issue at our end.
1,612
Posted By pravin27
Yes, you can pass the $error variable to awk as...
Yes, you can pass the $error variable to awk as you did for DT

awk -vDT=$(date +"%y%m%d%H%M" -d"- 3 hour") -vERROR=$error
2,001
Posted By pravin27
Could this help you ? script name - Forum1.pl ...
Could this help you ?
script name - Forum1.pl
#!/usr/bin/perl

my %hashTree;
my @array;

while (<>) {
chomp;
@array=split;
$hashTree{$array[0]}{$array[3]}=[$array[1] ,$array[2]];
}...
11,572
Posted By pravin27
Without BEGIN Block awk -F"|"...
Without BEGIN Block
awk -F"|" '$11="||||"$11"|ABC"' OFS="|" filename
1,209
Posted By pravin27
How about this ? awk...
How about this ?

awk 'NR==FNR{a[$(NF-1)]=$(NF-1);next}
{if (FNR==1) { asort(a) ; printf "Fam\t\tNo\t\tName\t" ; for ( j in a ) { printf a[j] FS }} if ( !b[$1,$2] ) { if ( FNR>1) { for(j in a)...
Showing results 1 to 25 of 285

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