Visit Our UNIX and Linux User Community

Search Results

Search: Posts Made By: pravin27
3,026
Posted By pravin27
Hi, Can you try job_depends command of autosys...
Hi,
Can you try job_depends command of autosys ?
Thanks
Pravin
2,288
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,046
Posted By pravin27
Hi , Try new code from post #6. Thanks ...
Hi ,
Try new code from post #6.

Thanks
Pravin
1,046
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 }...
959
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,126
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
1,889
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
...
1,889
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,373
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,218
Posted By pravin27
sed '/\[\/\]/a added' filename
sed '/\[\/\]/a added' filename
912
Posted By pravin27
awk -F";" '{if ($3"|"$4 != prev ) {print...
awk -F";" '{if ($3"|"$4 != prev ) {print }prev=$3"|"$4}' filename
3,915
Posted By pravin27
Its working fine at my end. try this, ...
Its working fine at my end.

try this,

awk '/Order Number=\"/ {a=$0;i=0;while(i<4){getline;a=a"\n"$0;i++};print a > ++j".xml"}' input.xml
3,915
Posted By pravin27
Try this, awk '/Order Number=\"/...
Try this,


awk '/Order Number=\"/ {a=$0;i=0;while(i<4){getline;a=a"\n"$0;++i};print a > ++j".xml"}' input.xml
2,045
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}")...
19,936
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
19,936
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
...
19,936
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.
2,624
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";
...
16,105
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}...
16,105
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...
828
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"...
1,727
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...
1,727
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]]}'...
1,428
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
1,420
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]];
}...
Showing results 1 to 25 of 285

 

Featured Tech Videos

All times are GMT -4. The time now is 08:14 AM.
Unix & Linux Forums Content Copyright 1993-2021. All Rights Reserved.
Privacy Policy