The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
.
google unix.com



UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
how to keep newline characters in command execution result? pankai Shell Programming and Scripting 2 01-02-2008 05:41 PM
Where we can get the logs for a command execution successfully? susinthaa SUN Solaris 4 07-10-2007 12:35 AM
Status code of last command execution tipsy Shell Programming and Scripting 1 07-21-2006 01:14 PM
Retrieving the execution time of a completed command marina UNIX for Dummies Questions & Answers 2 09-06-2005 04:21 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 11-01-2007
zedex zedex is offline
Registered User
  
 

Join Date: Feb 2007
Location: india,mumbai
Posts: 138
Exclamation command execution ??

hi i have small shell script as follows
Code:
   
cd /utilities/promoter/tmp
   grep SENDREPLY $1 | grep 'zzzzz@zzz.com' | awk -F"[" '{print $4}' | cut -d] -f1 > /tmp/$LOGNAME/$1.request
   cd /tmp/$LOGNAME
   grep -e "\.sql" -e "\.md" $1.request > upd_$1.txt
   grep -v -e "\.sql" -e "\.md" $1.request > copy_$1.txt
now when i execute this code in debug mode i get following output
Code:
(mhatrnin)hpux1570:/idcuser/mhatrnin>sh -x ./GenerateReq 13227
+ cd /utilities/promoter/tmp
+ grep SENDREPLY 13227
+ grep zzzzzz@zzz.com
+ cut -d] -f1
+ awk -F[ {print $4}
+ 1> /tmp/mhatrnin/13227.request
                      .
                      .
one thing i mnot getting is that why cut is 1st executed when its after awk in actual command ?
  #2 (permalink)  
Old 11-06-2007
sunsri01 sunsri01 is offline
Registered User
  
 

Join Date: Nov 2007
Posts: 11
There is no issue with the script, in debug mode it will display like that but AWK will execute first.
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 09:44 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0