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 > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
virus scanning options? robsonde SUN Solaris 0 03-02-2008 02:39 PM
Scanning file backwards tekster757 UNIX for Advanced & Expert Users 2 09-21-2007 05:07 PM
How to zip a modified file 15 days before but not scanning my sub directory files skrish70 Shell Programming and Scripting 1 10-10-2005 03:41 PM
Paging without Scanning Negm SUN Solaris 4 09-14-2005 07:58 AM
scanning empty directories N065956BM UNIX for Dummies Questions & Answers 7 02-18-2004 07:13 PM

 
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rating: Thread Rating: 1 votes, 5.00 average. Display Modes
Prev Previous Post   Next Post Next
  #1 (permalink)  
Old 10-08-2004
man80 man80 is offline
Registered User
  
 

Join Date: Oct 2004
Posts: 5
scanning for '0' value in .txt file

Hello

I am a novice shell scripting programmer, so please bare with me.

I have embedded a simple SQL statement into a shell script, which simply returns an integer (its a count (*) statement).

The result of the statement is then oputput to .txt file. So, the number could be 0, 1,2, 10, 50, 101 etc.

What I want to do is send an email if the number output into the .txt file is greater than 0. How do I check that the number output is 0, I thought about checking whether the file contained a 0, but I thought this may not work as it may also return a true value if the number was '10' or '100' etc.

Thanks
 

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 04:35 PM.


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