From: "Spalding, Steve" <SSPALDIN () mem-ins ! com>
To: tru64-unix-managers
Subject: inequalities in a case statement in ksh
Date: Tue, 31 Mar 1998 20:39:49 +0000 [thread overview]
Message-ID: <96078701111821.tru64-unix-managers.marc@archive.invalid> (raw)
Hello all!
Since my question earlier today went so well, I thought that I would try
another. I'm writing a script file using a case statement, and I want to
use inequalities with it but don't know how. Here is what I have right
now:
case "$capacity" in
[93 - 96] if [ $severity -lt 1 ];then
severity=1
fi #if [ $severity -lt 1 ];then
;;
[97 - 99] if [ $severity -lt 2 ];then
severity=2
page=true
fi #if [ $severity -lt 2 ];then
;;
100) if [ $severity -lt 3 ];then
severity=3
page=true
fi #if [ $severity -lt 3 ];then
;;
esac #case "$capacity" in
Let's say that in the last case I wanted to catch any value above 100
instead of just 100; how would I set that up? Here is what I have tried
using:
> 100 if [ $severity -lt 3 ];then
[ > 100 ] if [ $severity -lt 3 ];then
[ -gt 100] if [ $severity -lt 3 ];then
but nothing seems to want to work. Any ideas?
Thanks!
PS - Lawrence Decker - I tried responding to your email earlier, but I
keep getting this text in a returned mail message:
Your Message
To: 'ldecker@pbchcd.state.fl.us'
Subject: FW: Pop up message
Was not delivered for the following reasons:
Delivery failed to SMTP:ldecker@pbchcd.state.fl.us.
Reason: 0 (transfer failed)
diagnostic: 0 (OR name (Email address) unrecognized).
MSEXCH:IMS:MEM:EXCH1:MEM_CO_NT1 3902 (000B0981) Host Unknown.
Stephen Spalding
Associate System Administrator
sspaldin@mem-ins.com
Missouri Employers Mutual Insurance
reply other threads:[~1998-03-31 20:39 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox